Quantcast
Channel: SCN : All Content - SAP Gateway
Viewing all articles
Browse latest Browse all 2823

Exporting table through call method

$
0
0

Hello experts,

 

I'm trying to make my get_entity_set methode for a condition type:

 

DATA itab_cond_type TYPE TABLE OF zstruc_cond_type.

DATA wa_cond_type type zstruc_cond_type.

 

     CALL METHOD class->GET_COND_TYPE IMPORTING ex_cond_type  = itab_cond_type

         .

 

   DATA: ls_entityset LIKE LINE OF et_entityset.

 

LOOP AT itab_cond_type INTO wa_cond_type.

     ls_entityset-KSCHL = wa_cond_type-KSCHL.

     ls_entityset-class = wa_cond_type-VTEXT.

     APPEND ls_entityset TO et_entityset.

ENDLOOP.



I get an error at the import.   => "itab_cond_type" is not type-compatible with the

formal parameterr "ex_cond_type".

 

Even though they are both from the same type ... (type table of zstruc_cond_type).

 

When i change 'DATA itab_cond_type TYPE TABLE OF zstruc_cond_type' to 'DATA itab_cond_type TYPE zstruc_cond_type'

i get an error at the loop at because it is no longer an iternal table and i cannot append my data to et_entityset...

 

Any ideas of what it is i'm doing wrong here?

 

Kind regards,

 

Bart


Viewing all articles
Browse latest Browse all 2823

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>