2008 Apr 10 4:57 PM
Hi Experts,
This is wr.t nested strcutres while creating in ABAP proxies.SPROXY.
I have a workarea that contains fields say f1 f2..f5
Now i have an internal table itab (say) that is declared wr.t a structure that is inturn nested with 2 more structures internally say struct1 holds inturn strcu2 and finally struc2 contains some fields. note that there are no Table types used for itab.
Now i need to assign the fields of workarea above to itab.
i am getting errors like itab cannot be converted ..etc
Please help me How to do this.
I need to use this itab in
CALL METHOD zprxy->execute_asynchronous
EXPORTING
output = itab.
COMMIT WORK
Thanks
Dany
2008 Apr 10 5:54 PM
Hi,
You can use this example:
data: lt_xml_ref TYPE "Table type".
FIELD-SYMBOLS:
<fs_ref> LIKE LINE OF "Table Type".
LOOP AT lt_xml_ref ASSIGNING <fs_ref>.
CLEAR lw_ref .
APPEND lw_ref TO
znfe_sign_nfe_ob-nfe-inf_nfe-ide-nfref.
ENDLOOP.
znfe_sign_nfe_ob-nfe-inf_nfe-ide-nfref is the structure created regarding the abap proxy.
Fernando
Hi Experts,
This is wr.t nested strcutres while creating in ABAP proxies.SPROXY.
I have a workarea that contains fields say f1 f2..f5
Now i have an internal table itab (say) that is declared wr.t a structure that is inturn nested with 2 more structures internally say struct1 holds inturn strcu2 and finally struc2 contains some fields. note that there are no Table types used for itab.
Now i need to assign the fields of workarea above to itab.
i am getting errors like itab cannot be converted ..etc
Please help me How to do this.
I need to use this itab in
CALL METHOD zprxy->execute_asynchronous
EXPORTING
output = itab.
COMMIT WORK
Thanks
Dany
2008 Apr 10 5:53 PM
You have to use field symbols to populate or read data from/to nested structures.
Thanks,
Srinivas
2008 Apr 10 5:54 PM
Hi,
You can use this example:
data: lt_xml_ref TYPE "Table type".
FIELD-SYMBOLS:
<fs_ref> LIKE LINE OF "Table Type".
LOOP AT lt_xml_ref ASSIGNING <fs_ref>.
CLEAR lw_ref .
APPEND lw_ref TO
znfe_sign_nfe_ob-nfe-inf_nfe-ide-nfref.
ENDLOOP.
znfe_sign_nfe_ob-nfe-inf_nfe-ide-nfref is the structure created regarding the abap proxy.
Fernando
2008 Apr 10 11:04 PM
Hi Epxerts,
Can someone give me an idea of passing multiple records in the parameter it_prxkna1 below :
I am working on this to pass it to XI.
Please note that it_prxkna1 contains a 3 more nested structures and not an internal table.
TRY.
Assign row
it_prxkna1-MT_KNA1_EXTRACT-record-row = wa_zcaap. --> one record of a customer
loop at t_zcaap into wa_zcaap.
CALL METHOD kna1_prxy->execute_asynchronous
EXPORTING
output = it_prxkna1.
COMMIT WORK.
endloop.
CATCH cx_ai_system_fault .
DATA fault TYPE REF TO cx_ai_system_fault .
CREATE OBJECT fault.
WRITE 😕 fault->errortext.
ENDTRY.
Please suggest.
Thanks
Dany