Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Creating Employee master data XML

former_member500520
Discoverer
0 Likes
369

Hello all,

I have a requirement in which I need to write a program that retrieves employeee master data and create XML output. I know how to retrieve employee master data and I am using logical database PNP and all that but I am just wondering if there is any function module/class from SAP that gives me employee master data directly in XML format!

I did reserach on SDN but could not find much information. If there is no FM module available, could someone please give me some ideas on how I can create an XML output of the employee master data?

Thanks.

Mithun

1 REPLY 1
Read only

Former Member
0 Likes
325

Hello Ravi,

Try this way:

Read master data into internal table.

use call transformation to convert that internal table data into XML.

You can use call transformation as follows:



DATA ITAB TYPE TABLE OF <master data table> WITH HEADER LINE...
DATA XML_STRING TYPE STRING.

CALL TRANSFORMATION ID
           SOURCE MATDAT = ITAB[]
            RESULT XML XML_STRING.

Hope this helps!

Thanks,

Augustin.