‎2006 Oct 10 7:08 AM
Hi experts,
i am currently experiencing difficulty trying to convert this xml into abap internal table.
I am trying to use XSLT to convert this XML but unsuccessful so far.
<I_DATA>
<NAME1>john</NAME1>
<NAME2>smith</NAME2>
<CONT>
<CONTENT1>STREAM ROAD</CONTENT1>
<CONTENT2>ENGLAND</CONTENT2>
<CONTENT1>CROSS STREET</CONTENT1>
<CONTENT2>MALAYSIA</CONTENT2>
</CONT>
<NAME1>MICHAEL</NAME1>
<NAME2>CAGE</NAME2>
<CONT>
<CONTENT1>HABOUR STREET</CONTENT1>
<CONTENT2>SINGAPORE</CONTENT2>
<CONTENT1>RANCH ROAD</CONTENT1>
<CONTENT2>AMERICA</CONTENT2>
</CONT>
</I_DATA>
This is the internal table:
TYPES: BEGIN OF CONTENT,
CONTENT1(20),
CONTENT2(20),
END OF CONTENT.
TYPES: T_CONTENT TYPE TABLE OF CONTENT.
DATA: BEGIN OF I_DATA_table,
KEY1(10),
KEY2(10),
CONT TYPE T_CONTENT,
END OF I_DATA_table.
DATA: I_DATA type table of I_DATA_TABLE.
Can anyone please shine some light on this?
Many thanks in advance~!
‎2006 Oct 10 7:10 AM
Hi,
See the below link for program which is uploading the XML file in to SAP, this will work in 4.6C
use this XML file for the above program:
See the below link for one more program
http://wiki.ittoolbox.com/index.php/Code:Download_and_upload_OO_ABAP_class_in_XML_format
Regards
Sudheer
‎2006 Oct 10 7:18 AM
Thanks Sudheer~! but i would like to use XSLT to solve this problem.
Thanks again so much for the information! Points have been awarded.
‎2006 Oct 15 11:40 AM