ABAP MAPPING SAMPLE SOURCE

Hi,
I have to make abap mapping like bellow it.
Sender
<?xml version="1.0" encoding="UTF-8"?>
<ns0:Legacy_Msg xmlns:ns0="http://test/xi/test001">
     <item>
          <A>TEST1</A>
          <B>TEST2</B>
     </item>
     <item>
          <A>TEST2</A>
          <B>TEST3</B>
     </item>
</ns0:Legacy_Msg>
Receiver
<?xml version="1.0" ?>
<MsgOut>
     <item>
          <C>TEST1</C>
          <D>TEST2</D>
     </item>
     <item>
          <C>TEST2</C>
          <D>TEST3</D>
     </item>
</MsgOut>
I want to get result like over.
I don't know how to code abap mapping.
Please help me.
Thanks.

check "How to Use ABAP Mapping in XI 3.0" in this
http://www.erpgenie.com/sap/netweaver/xi/howto.htm

Similar Messages

  • Little abap mapping sample

    Hi everyone.
    I'm a two years old abap programmer and i would like to understand how abap mapping works.
    I've read a sap document with a code sample but i don't understand it very well.
    I've defined a message type containing 2 fields, name and age. This structure has cardinality of 1..unbounded.
    I want to make and abap mapping and have one outbound estructure containing the result of the 'collect' instruction' in abap. the output structure is the same as the input one.
    Thanks for the help.

    inigo,
    I have seen many of your posts and you did not assign  points to the folks who answered.
    I request you to reward the people who have replied to your posts. IF you consider that the replies have helped u , assign
    2 points -- helpful
    6 points -- very helpful
    10 points -- problem solved..
    If u are not able to see the assign point s button refer to this thread...
    Unable to award points
    People in the forum spend their valuable time answering questions. It is courtesy to do so.
    regards
    Shravan

  • XSLT samples for XML- ABAP mapping

    Hi all,
    Does anyone have a XSLT samples for XML->ABAP mapping ?
    regards

    first create XSLT program by copy pasting the below given code and give the program name as "Y_TEST"
    <b>XSLT code</b>
    <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
      <xsl:strip-space elements="*"/>
      <xsl:output indent="yes"/>
      <xsl:template match="NewDataSet">
        <asx:abap xmlns:asx="http://www.sap.com/abapxml" version="1.0">
          <asx:values>
            <OUTTAB>
              <xsl:for-each select="Table">
                <OUTTAB1>
                  <AIRPORTCODE>
                    <xsl:value-of select="AirportCode"/>
                  </AIRPORTCODE>
                  <CITYOFAIRPORTNAME>
                    <xsl:value-of select="CityOrAirportName"/>
                  </CITYOFAIRPORTNAME>
                  <COUNTRY>
                    <xsl:value-of select="Country"/>
                  </COUNTRY>
                  <COUNTRYABBRIVATION>
                    <xsl:value-of select="CountryAbbrviation"/>
                  </COUNTRYABBRIVATION>
                  <COUNTRYCODE>
                    <xsl:value-of select="CountryCode"/>
                  </COUNTRYCODE>
                  <GMTOFFSET>
                    <xsl:value-of select="GMTOffset"/>
                  </GMTOFFSET>
                  <RUNWAYLENGTHFEET>
                    <xsl:value-of select="RunwayLengthFeet"/>
                  </RUNWAYLENGTHFEET>
                  <RUNWAYELEVATIONFEET>
                    <xsl:value-of select="RunwayElevationFeet"/>
                  </RUNWAYELEVATIONFEET>
                  <LATITUDEDEGREE>
                    <xsl:value-of select="LatitudeDegree"/>
                  </LATITUDEDEGREE>
                  <LATITUDEMINUTE>
                    <xsl:value-of select="LatitudeMinute"/>
                  </LATITUDEMINUTE>
                  <LATITUDESECOND>
                    <xsl:value-of select="LatitudeSecond"/>
                  </LATITUDESECOND>
                  <LATITUDENPEERS>
                    <xsl:value-of select="LatitudeNpeerS"/>
                  </LATITUDENPEERS>
                  <LONGITUDEDEGREE>
                    <xsl:value-of select="LongitudeDegree"/>
                  </LONGITUDEDEGREE>
                  <LONGITUDEMINUTE>
                    <xsl:value-of select="LongitudeMinute"/>
                  </LONGITUDEMINUTE>
                  <LONGITUDESECONDS>
                    <xsl:value-of select="LongitudeSeconds"/>
                  </LONGITUDESECONDS>
                  <LONGITUDEEPERW>
                    <xsl:value-of select="LongitudeEperW"/>
                  </LONGITUDEEPERW>
                </OUTTAB1>
              </xsl:for-each>
            </OUTTAB>
          </asx:values>
        </asx:abap>
      </xsl:template>
    </xsl:stylesheet>
    <b>just create a type 1 program and paste the below given code.</b>
    report y_consume_webservice .
    data: wf_user type string .
    data: wf_password type string .
    types: begin of outtab1 ,
       airportcode(6)  ,
       cityofairportname(50),
       country(30)  ,
       countryabbrivation(10),
       countrycode(6)  ,
       gmtoffset(10)  ,
       runwaylengthfeet(15),
       runwayelevationfeet(15),
       latitudedegree(10)  ,
       latitudeminute(10)  ,
       latitudesecond(10)  ,
       latitudenpeers(10)  ,
       longitudedegree(10)  ,
       longitudeminute(10)  ,
       longitudeseconds(10)  ,
       longitudeeperw(10) ,
       end of outtab1 .
    data: outtab type  table of outtab1.
    data: wf_o like line of outtab .
    data: g_okcode like sy-ucomm .
    data: my_container   type ref to cl_gui_custom_container .
    data: g_dock type ref to cl_gui_docking_container .
    data: mygrid type ref to cl_gui_alv_grid .
    data: wf_field_cat type lvc_t_fcat .
    data: wf_field_cat_wa like line of wf_field_cat ,
          wf_is_layout type lvc_s_layo .
    data: wf_fld_cat type slis_t_fieldcat_alv .
    data: wf_fld_cat_wa like line of wf_fld_cat .
    data: wf_repid like sy-repid .
    data: int_tab_name type slis_tabname .
    data: xslt_err type ref to cx_xslt_exception .
    constants:
    * encoding for download of XML files
    encoding     type string value 'utf-8' .
    data: rlength type i,
          txlen type string  .
    data: http_client type ref to if_http_client .
    data: wf_string type string .
    data: wf_string1 type string .
    data: wf_proxy type string ,
          wf_port type string .
    selection-screen: begin of block a with frame .
    parameters: uri2(132) type c lower case .
    selection-screen skip 1.
    parameters: user(50) lower case,
                password(50) lower case ,
                p_proxy(100) lower case default 'proxy.xxx.com' ,
                p_port(4) default '80'.
    selection-screen: end of block a .
    at selection-screen output.
      loop at screen.
        if screen-name = 'PASSWORD'.
          screen-invisible = '1'.
          modify screen.
        endif.
      endloop.
    start-of-selection .
    clear wf_string .
    concatenate
    '<?xml version="1.0" encoding="utf-8"?>'
    '<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">'
    '<soap:Body>'
    '<GetAirportInformationByCountry xmlns="http://www.webserviceX.NET">'
    '<country>' uri2 '</country>'
    '</GetAirportInformationByCountry>'
    '</soap:Body>'
    '</soap:Envelope>'
    into wf_string .
    clear :rlength , txlen .
    rlength = strlen( wf_string ) .
    move: rlength to txlen .
    clear: wf_proxy, wf_port .
    move: p_proxy to wf_proxy ,
          p_port to wf_port .
    call method cl_http_client=>create
      exporting
        host          = 'www.webservicex.net'
        service       = '80'
        scheme        = '1'
        proxy_host    =  wf_proxy
        proxy_service =  wf_port
      importing
        client        = http_client.
    http_client->propertytype_logon_popup = http_client->co_disabled.
    wf_user = user .
    wf_password = password .
    call method http_client->authenticate
      exporting
        proxy_authentication = 'X'
        username             = wf_user
        password             = wf_password.
    call method http_client->request->set_header_field
      exporting
        name  = '~request_method'
        value = 'POST'.
    call method http_client->request->set_header_field
      exporting
        name  = '~server_protocol'
        value = 'HTTP/1.1'.
    call method http_client->request->set_header_field
      exporting
        name  = '~request_uri'
        value = '/airport.asmx'.
    call method http_client->request->set_header_field
      exporting
        name  = 'Content-Type'
        value = 'text/xml; charset=utf-8'.
    call method http_client->request->set_header_field
      exporting
        name  = 'Content-Length'
        value = txlen.
    call method http_client->request->set_header_field
      exporting
        name  = 'SOAPAction'
        value = 'http://www.webserviceX.NET/GetAirportInformationByCountry'.
    call method http_client->request->set_cdata
      exporting
        data   = wf_string
        offset = 0
        length = rlength.
    call method http_client->send
      exceptions
        http_communication_failure = 1
        http_invalid_state         = 2.
    call method http_client->receive
      exceptions
        http_communication_failure = 1
        http_invalid_state         = 2
        http_processing_failed     = 3.
    clear wf_string1 .
    wf_string1 = http_client->response->get_cdata( ).
    replace all occurrences of
        '<' in wf_string1 with '<' .
    replace all occurrences of
    '>' in wf_string1 with '>' .
    replace all occurrences of
    'xmlns=' in wf_string1 with 'xmlns:xsl=' .
    try .
        call transformation (`Y_TEST`)
                source xml wf_string1
                result     outtab = outtab.
      catch cx_xslt_exception into xslt_err.
        data: s type string.
        s = xslt_err->get_text( ).
        write: ': ', s.
        stop.
    endtry .
    break-point .
    Try this and give me your feedback.
    Regards
    Raja

  • ABAP MAPPING Querry - How to create Different Target NODE NAME as of Source

    Hi,
    In abap Mapping
    <b>DATA READ FROM SOURCE XML NODE into <u>incode</u></b> ******
    data: incode type ref to if_ixml_node_collection.
    incode = idocument->get_elements_by_tag_name( 'BUSINESS_DAY' ).
    <b>CREATE OUTPUT XML NODE WITH SAME NAME AS <u>'BUSINESS_DAY'</u></b> **
    data: outcode type ref to if_ixml_node.
    outcode = incode->get_item( index = 0 ).
    data irc type i.
    irc = msgtype->append_child( outcode ).
    *<b>BUT TO CREATE OUTPUT XML NODE WITH <u>DIFFERENT NAME AS 'BUSS_DAY'</u></b>*
    data: ws_val type string VALUE 'xyz'.
    data: elementsender type ref to if_ixml_element.
    elementsender = odocument->create_simple_element(
    name = 'BUSS_DAY'
    value = ws_val
    parent = msgtype ).
    <b>Please guide me how I can assign <u>incode</u> value to ws_val.
    So that I can generate <u>OUTPUT XML NODE with different name as of SOURCE XML NODE</u></b>
    i.e. How to create Different Target NODE NAME as of
    Source with same Data
    <Note>: I am using "How to... Use ABAP Mapping in XI 3.0 ver.1.00" and to create different NODE name as of source
    is not given in it.
    Thanks & Regards.

    Hi ABAPers,
    Please Guide Me .....
    <u>This is ABAP Mapping problem in XI.</u>
    <b>How can I read data from incode into ws_val.</b>
    data: <b>ws_val</b> type string
    data: <b>incode</b> type ref to if_ixml_node_collection.
    <b>incode</b> = idocument->get_elements_by_tag_name( 'BUSINESS_DAY' ).
    Best Regards

  • ABAP Mapping doubt

    Hi.
    I'm trying to do an abap mapping. I've read weblogs from Robert Eijpe. The samples contained in the weblog worked fine but i have a doubt.
    ABAP class had a parameter called SOURCE. This parameter contains the XML but i think is contained in only one line. In the sample weblog, the XML is contained in an internal table.
    Question is ... how can i transform this SOURCE of 1 line into an internal table?
    Thanks.

    Hi Inigo,
    Please look at this..
    http://help.sap.com/saphelp_nw2004s/helpdata/en/ba/e18b1a0fc14f1faf884ae50cece51b/frameset.htm
    Hope it helps you!
    cheers,
    Prashanth

  • ABAP Mapping : Link to the repository

    Hello,
    I'm taking a look at PI Mapping with ABAP. In the documentation I find how I have to program the ABAP part, but I am missing the link with the messages defined in P.
    I made a class 'ZA_CL_KCL_MAPPING' with interface IF_MAPPING in it.
    I made the changes to the exchange profile, putting 'R3ABAP|ABAP-Class;R3XSLT|XSL (ABAP Engine)' in 'com.sap.aii.repository.mapping.additionaltypes'.
    What is the step by step process to make my ABAP mapping really work ? Where do I put my missing link .
    Thanks in advance.
    Kris

    Try giving this entry in Exchage Profile under  IntegrationBuilder>IntegrationBuilder.Repository>com.sap.aii.repository.mapping.additionaltypes
    R3_ABAP|Abapclass;R3_XSLT|XSL (ABAP Engine)
    Close IR and Reopen. Now in interface mapping you can select the ABAP Mapping Type. Then give your abap class name there exactly what you defined in SE38.
    Activate and test using Test tab of Interface Mapping. Use some sample payload of Source XML which you should be knowing.
    Note:- Message Mapping is not required.
    Regards,
    - Gujjeti.
    Edited by: Praveen Gujjeti on Mar 23, 2009 7:35 PM

  • ABAP Mapping Questions

    Hi,
    I am trying to get my head around ABAP mappings and have a few questions.
    In the below code sample which I find in every example and blog it talks about specific steps -
    *initialize iXML, * create iXML factory object, * create streamfactory object, * create input stream object, * initialize the input xml document, * parse the input xml document
    In these steps the code is always exactly the same so my question is are these just standard steps that are implemented every single time an abap mapping is used and hence only standard lines that never have to be changed or will they be different depending on the mapping.
    I am trying to work out where I will begin my coding.
    So would somebody be so kind as to give me a brief explanation of the above mentioned steps.
    Thank you
    METHOD if_mapping~execute.
    * initialize iXML
      TYPE-POOLS: ixml.
      CLASS cl_ixml DEFINITION LOAD.
    * create iXML factory object
      DATA: ixmlfactory TYPE REF TO if_ixml.
      ixmlfactory = cl_ixml=>create( ).
    * create streamfactory object
      DATA: streamfactory TYPE REF TO
      if_ixml_stream_factory.
      streamfactory = ixmlfactory->create_stream_factory( ).
    * create input stream object
      DATA: istream TYPE REF TO if_ixml_istream.
      istream = streamfactory->create_istream_xstring( source ).
    * initialize the input xml document
      DATA: idocument TYPE REF TO if_ixml_document.
      idocument = ixmlfactory->create_document( ).
    * parse the input xml document
      DATA: iparser TYPE REF TO if_ixml_parser.
      iparser = ixmlfactory->create_parser(
      stream_factory = streamfactory
      istream = istream
      document = idocument ).
      iparser->parse( ).

    Hi,
         The above lines you mentioned deal with initialization of the iXML parser for parsing through the XML payload, so they would remain the same for all mapping where you are parsing the input payload.
    The coding for you specific mapping will begin after this, something like :
    * Implements the DOM generating interface to the parser
      iparser->parse( ).
      emp_node_collection = idocument->get_elements_by_tag_name_ns( name = 'Order' ).
      emp_node_length = emp_node_collection->get_length( ).
      emp_node_iterator = emp_node_collection->create_iterator( ).
    where you start reading the xml node values.
    Hope this helps.
    Regards

  • Has any one ever met this kind of ABAP-mapping problem ??

    Dear all,
    our scenario is:     
    (remote)MQ(ssl connection)->(local)MQ-(jms)>XI---(proxy)>ECC
    I met a very strange question during mapping which we use  abap mapping inside xi.
    the message come out from the abap mapping step.after the abap-mapping, the generated target message still has the source message concatenated with. it occurs only when all servers integrated together, but not occurs when we mannully put the source msg at local MQ (means this way, it works all right).
    even during error case, it still can go through all the remaining steps of IE, and the out bound jms adapter then goes into the
    target SAP ECC system, but of cause at the final step, it will reach u2018CX_ST_GROUP_MISSING_CASEu2019 error (this is because the message is not a valid xml file, and abap proxy can not consume it...
    sample file after abap mapping:
    <?xml version="1.0" encoding="utf-8"?>
    <ns:MT_MQIVMessage xmlns:ns="urn:ianes:mqiv">
         <MQIVMessage>
         <MQIVPayload> ..data..</MQIVPayload>
         </MQIVMessage>
    </ns:MT_MQIVMessage>
    <?xml version="1.0"?>
    <ns:MT_K2 xmlns:ns="urn:ianes:prp:ipsc">
         <header> .header.</header>
         <data>..data...</data>
    </ns:MT_K2>

    Dear expert,
    after detail analysis, i found the 1st place that the soap header was wrongly set...
    in call adater setp...
    <SAP:Sender>
      <SAP:Service>BS_PRP</SAP:Service>
      <SAP:Interface namespace="urn:ianes:ext:ips">MI_MQIV_outb</SAP:Interface>
      </SAP:Sender>
      <SAP:Receiver>
      <SAP:Party agency="" scheme="" />
      <SAP:Service>BS_SAP</SAP:Service>
      <SAP:Interface namespace="urn:ianes:prp:ipsc">MI_K3</SAP:Interface>
      </SAP:Receiver>
      <SAP:Interface namespace="urn:ianes:prp:ipsc">MI_K5</SAP:Interface>
      </SAP:Main>
    you can see the k5  was wrong set to k3
    correct soap header should be this
    <SAP:Sender>
      <SAP:Service>BS_PRP</SAP:Service>
      <SAP:Interface namespace="urn:ianes:ext:ips">MI_MQIV_outb</SAP:Interface>
      </SAP:Sender>
    - <SAP:Receiver>
      <SAP:Party agency="" scheme="" />
      <SAP:Service>BS_SAP</SAP:Service>
      <SAP:Interface namespace="urn:ianes:prp:ipsc">MI_K5</SAP:Interface>
    - <SAP:Mapping notRequired="M">
      <SAP:ObjectId>RXmJZiHCMPynqzPehi20YQ==</SAP:ObjectId>
      <SAP:SWCV>z+4XcK+qEduCcMP2oNwEVQ==</SAP:SWCV>
      <SAP:SP>-1</SAP:SP>
      </SAP:Mapping>
      </SAP:Receiver>
      <SAP:Interface namespace="urn:ianes:prp:ipsc">MI_K5</SAP:Interface>
      </SAP:Main>
    i guess this is the root of error, does any one give some hints on this ?
    Thanks
    Wu

  • Acces dynamic configuration variable (e.g. filename) in ABAP mapping class

    Hi experts
    I am searching for a possibility to acces a dynamic configuration variable (DCV) in an ABAP mapping class. Since I could not find a solution in SDN and other sources, I hope somebody in this forum can help me.
    What I already found is the following code which can be used to set a DCV, but what I would be interested in is how to read a DCV.
    Any help is appreciated.
    Markus
    METHOD if_mapping~execute.
    DATA l_record type mpp_dynamic.
    * copy payload
    result = source.
    * add an adapter specific attribute
    l_record-namespace = 'http://sap.com/xi/XI/System/File'.
    l_record-name = 'FileName'.
    l_record-value = 'test.xml'.
    dynamic_configuration->add_record( l_record ).
    ENDMETHOD.

    Hi Markus,
    you can find everything in my blogs
    /people/michal.krawczyk2/blog/2007/04/26/xipi-throwing-generic-exceptions-from-any-type-of-mapping
    Regards,
    michal

  • Key Mapping Sample

    Hi
    Is there any simple key mapping sample?
    I would like to create a protoype loading (manually) a materials base from different sources (companies) and later try to create key mapping, in order to understand how this key mapping works.
    Regards,
    Ronaldo.

    Hi Roman
    Thanks for your answer.
    As I am beginner in MDM, I am not even sure if key mapping is what I need.
    What I want to do is:
    - Simulate a group with 3 companies. In this group each company has its own materials database. So, let's suppose a certain material has a different code in each company.
    - In company A, this material is called A1.
    - In company B, this material is called B1.
    - And in company C, C1.
    After these material bases have been loaded in MDM, someone would analyze these products, and based on there coincident physical characteristics conclude: OK, all are the same material. All these materials would receive a UNIQUE identification, which could be used to generate cross-company reports, allowing these "different" products be grouped together (or compared).
    This UNIQUE Identification should be something like below:
    Product  Company   Unique Code
    A1       A         X001
    B1       B         X001
    C1       C         X001
    Is that the objective of Key mapping?
    If so, I am having some problems to make it works:
    - There is a agency field in Key Mapping. What it means? Would it be the same as "company" in example above? If so, why there is no Agency field in records that I insert manually...I feel I am missing some important concept here.
    - When I insert a key mapping for my second product, the key mapping for the first one is delete. Why?
    Definitively I know that my questions are very basic (and boring, probably). If there is a tutorial for newbies, I would appreciate.
    Regards,
    Ronaldo.

  • ABAP mapping split messages and dynamic filename

    Hello,
    i have set up a IDOC to file scenario where the IDOC is split into several files, which works fine. In addition to this it is required to set a dynamic filename out of the ABAP mapping for each file. If only one file is created this works already as well but how do you set the dynamic configuration when the messages are split?
    Regards,
    Andreas
    Edited by: Andreas on Feb 26, 2009 9:09 AM

    you cannot do dynamic configuration for message splits. The below is from SAP help.
    Adapter-Specific Attributes and Multi-Mappings
    In multi-mappings, there are multiple message headers with adapter-specific attributes. The mapping API can only access one message header. This has the following consequences depending on whether there are multiple source or target messages:
    u25CF     1:n Transformation
    If there are multiple target messages, the header for the adapter-specific attributes is copied for each message. This means that you can only create one header for all adapter-specific attributes, and not individual headers.
    u25CF     n:1 Transformation
    This variant is only possible for multi-mappings in integration processes. If there is more than one source message, read-access to the adapter-specific attributes of the various message headers is not possible at runtime.
    u25CF     m:n Transformation
    All afore-mentioned restrictions apply here. Developers can at most write the same adapter-specific attributes for all target messages to the header, without read-access to the attributes of the source messages. m:n transformations are only supported within integration processes.
    What i will suggest is to use BPM to have the message split i.e 1:N mapping and then after that have another mapping 1-1 to have the dynamic configuration

  • Dynamic configuration in ABAP Mapping

    Dear All,
    I have requirement to use the filename's name in the mapping to the target message.
    e.g: Filename is Victor.303, i need to take this 303 and map it to the target message.
    I understand i can get that value using dynamic configuration in Adapter-Specific Attributes.
    But all the samples are using Java code used in UDF.
    How to do the same in ABAP Mapping?
    I tried:
       record =  dynamic_configuration->get_record( namespace = 'http://sap.com/xi/XI/System/File'
                                                        name = 'FileName').
    But record-value return blank.
    Best Regards,
    Victor.

    Dear Prateek,
    I changed my code with:
      DATA: record TYPE mpp_dynamic.
      CALL METHOD dynamic_configuration->get_record
        EXPORTING
          namespace = 'http://sap.com/xi/XI/System/File'
          name      = 'FileName'
        RECEIVING
          record    = record.
    but record-value still return as blank.
    I have doubt in this, do i need to populate the FileName in the dynamic configuration (in the graphical mapping) first before i can get the value in the ABAP mapping? or System should filled it and i just can use it directly in the ABAP mapping?
    How we know what is the available name and namespace in that dynamic configuration-->get record??
    (e.g: my case is FileName, and in the link that you gave is ERROR.)
    Any link for this?
    Best Regards,
    Victor.

  • Any website for XSLT AND ABAP mapping

    Hi XI experts,
    I am looking for any good website/Material for XSLT and ABAP Mapping with examples.
    So experts if you any one of you have any clue , i would appreciate it , if you post the info here .
    Regds,
    Ram.

    Hi,
    For XSLT mapping, please try to create msg types for sender and recv, import these two into XML Mapforces (This is a software which enables us to do mapping this you can download from altova mapforce site) , do mapping in that mapforce , late click on XSLT icon , one XSLT file will be c reated that file , prepare zip and late come to xi , import under imported archieves,do Interface mapping by selecting the XSLT mapping option, select imported archieve..
    See below examples..
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/01a57f0b-0501-0010-3ca9-d2ea3bb983c1
    http://www.troobloo.com/tech/xslt.toc.shtml
    http://www.w3schools.com/xsl/
    http://www.w3.org/TR/xslt
    http://help.sap.com/saphelp_nw04/helpdata/en/73/f61eea1741453eb8f794e150067930/frameset.htm
    https://sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/xi/xi-code-samples/generic%20xslt%20mapping%20in%20sap%20xi%2c%20part%20i.pdf
    /people/anish.abraham2/blog/2005/12/22/file-to-multiple-idocs-xslt-mapping
    Required XSLT Mapping tips!
    Regards
    Chilla..

  • Graphical Mapping Vs XSLT mapping Vs Java Mapping Vs ABAP Mapping

    Hi Experts,
              I have a question regarding different message mapping options available in XI namely
    Graphical Mapping
    XSLT mapping
    Java Mapping
    ABAP Mapping
    Q1: Which amoung the above mappings is the best and why?
    Q2: On what cases Graphical, XSLT, Java and ABAP Mapping should be used?
    Q3: Is it true that graphical and XSLT mappings are converted into Java class internally?
    Kindly help!
    Thanks
    Gopal
    Message was edited by:
            gopalkrishna baliga

    Hi,
    There is no hard and fast rule for using the mapping techniques.
    Graphical Mapping is used for simple mapping cases. When, the logic for your mapping is simple and straight forward and it does not involve mult hiearchical mapping requirement. and context handling.
    Java and XSLT mapping are used when graphical mapping cannot help you.
    When the choice is between Java And XSLT, XSLT is simpler than java mapping and easier. But, it has its drawbacks.  XSLT can lead to a bad perfrormance if the Source XML is huge.
    Java Mapping uses 2 types of parsers. DOM and SAX. DOM is easier to use with lots of classes to help you create nodes and elements, but , DOM is very processor intensive.
    SAX parser is something that parses your XML one after the other, and so is not processor intensive. But, it is not exaclty easy to develop either.
    For further info on each of the mapping, refer to these links,
    Graphical Mapping,
    http://help.sap.com/saphelp_nw04/helpdata/en/6d/aadd3e6ecb1f39e10000000a114084/content.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/43/c4cdfc334824478090739c04c4a249/content.htm
    XSLT Mapping
    http://help.sap.com/saphelp_nw04/helpdata/en/73/f61eea1741453eb8f794e150067930/content.htm
    http://www.w3.org/TR/xslt20/
    Java Mapping
    http://help.sap.com/saphelp_nw04/helpdata/en/e2/e13fcd80fe47768df001a558ed10b6/content.htm
    DOM parser API
    http://java.sun.com/j2se/1.4.2/docs/api/org/w3c/dom/package-frame.html
    Also, check this thread for more info,
    Different types of Mapping in XI
    Am not sure about XSLT , but , yes graphical mapping is converted into java classes internally and these classes use SAX parsing as well.
    Regards,
    Bhavesh

  • Java Mapping, XSLT Mapping, ABAP Mapping

    Hi Experts,
                     Could any one explain what is the main features of the following Mapping. How to pick the mapping?
    Java Mapping - When to use and what is the advantage.
    ABAP Mapping - When to use and what is the advantage.
    XSLT Mapping - When to use and what is the advantage.
    Graphical Mapping - When to use and what is the advantage.
    cheers,
    Sunee

    There are 4 types of mapping in XI
    1. Graphical Mapping
    2. XSLT Mapping
    3. JAVA Mapping
    4. ABAP Mapping
    When to use Message mapping
    1 When the logic for your mapping is simple and straight forward, you can use
    Advantages of message mapping
    1)Easy to use.
    2) has GUI drag and drop.
    3) used for simple mapping cases
    4) it does not involve any complex logic
    Disadvantages of message mapping
    1)has limitation in terms of complex hierarchy
    When to use Java mapping
    1) Java mapping are used when graphical mapping cannot help you.
    Advantages of Java Mapping
    1)you can use Java APIs and Classes in it.
    2) file look up or a DB lookup is possible
    3) DOM is easier to use with lots of classes to help you create nodes and elements.
    Disadvantages of Java mapping
    1)SAX parser is not easy to develop
    2)DOM parser is intensive
    3) Java knowledge is required
    4) bit complexer
    XSLT Mapping - When to use
    1)When the required output is other than XML like Text, Html or XHTML (html displayed as XML )
    2)When default namespace coming from graphical mapping is not required or is to be changed as per requirements.
    3)When data is to be filtered based on certain fields (considering File as source)
    4)When data is to be sorted based on certain field (considering File as source)
    5)When data is to be grouped based on certain field (considering File as source)
    Advantages of using XSLT mapping
    1)XSLT program itself defines its own target structure.
    2)XSLT programs can be imported into SAP XI. Message mapping step can be avoided. One can directly go for interface mapping once message interfaces are created and mapping is imported.
    3)XSLT provides use of number of standard XPath functions that can replaces graphical mapping involving user defined java functions easily.
    4)File content conversion at receiver side can be avoided in case of text or html output.
    5)Multiple occurrences of node within tree (source XML) can be handled easily.
    6)XSLT can be used in combination with graphical mapping.
    7)Multi-mapping is also possible using xslt.
    8)XSLT can be used with ABAP and JAVA Extensions
    Disadvantages of using XSLT mapping
    1)Resultant XML payload can not be viewed in SXMB_MONI if not in XML format (for service packs < SP14).
    2)Interface mapping testing does not show proper error description. So errors in XSLT programs are difficult to trace in XI but can be easily identified outside XI using browser.
    3)XSLT mapping requires more memory than mapping classes generated in Java.
    4)XSLT program become lengthier as source structure fields grows in numbers.
    5)XSLT program sometimes become complex to meet desired functionality.
    6)Some XSL functions are dependent on version of browser.
    Advantages of Abap Mapping
    1) A person comfortable with OOABAP can go for ABAP mapping instead.
    Disadvantages of Abap Mapping
    1) Abap knowledge is required
    2) bit compexer
    For further info on each of the mapping, refer to these links,
    Graphical Mapping,
    http://help.sap.com/saphelp_nw04/helpdata/en/6d/aadd3e6ecb1f39e10000000a114084/content.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/43/c4cdfc334824478090739c04c4a249/content.htm
    XSLT Mapping
    http://help.sap.com/saphelp_nw04/helpdata/en/73/f61eea1741453eb8f794e150067930/content.htm
    http://www.w3.org/TR/xslt20/
    Java Mapping
    http://help.sap.com/saphelp_nw04/helpdata/en/e2/e13fcd80fe47768df001a558ed10b6/content.htm
    DOM parser API
    http://java.sun.com/j2se/1.4.2/docs/api/org/w3c/dom/package-frame.html
    Check this blog on Mapping:
    /people/ravikumar.allampallam/blog/2005/02/10/different-types-of-mapping-in-xi
    Also, check this thread for more info,
    Different types of Mapping in XI

Maybe you are looking for

  • How do i transfer movies purchased in itunes to a new computer?

    I would appreciate advice on how to transfer movies that i purchased on itunes from an old computer to a new one?  I have figured out the music and podcasts but the movies and tv shows are not transferring.  Advice?  thanks!

  • Mac OS X won't boot--tried everything

    I did the Quicktime update that came out a few days ago... When I restarted, everything went okay until the "Mac OS X" screen. It went about a half a centimeter on the progress bar in the "Mac OS X" window and then the window disappeared and I was fa

  • Date issue, need help on this one.

    Can anyone show me the proper ways of how to update the SQL date type? I can't insert records into table because of the "date" problem. Thanks in advance. Yee Hiong. import java.awt.*; import java.awt.event.*; import java.sql.*; import javax.swing.*;

  • JDBC Scenario

    Hi Experts,                   I am working on Sender JDBC Scenario........in sender JDBC Communication channel, there some important parameter <b>Query SQL Statement </b>(for select data records with specified condition) and <b>Update SQL Statement</

  • Opatch lsinventory does not work

    Oracle 9.2.0.8 We just applied JanCPU patch on this box. When I try to do opatch lsinventory it gives Exception in thread "main" java.lang.NoClassDefFoundError: javax/xml/transform/S ource at opatch.LsInventory.getOneOffList(LsInventory.java:671) at