Error in ABAP Mapping (type SAP-ABAP, kernel error ID UNCAUGHT_EXCEPTION)

Hi ,
  Scenario:  Manually Purchase Order is created, automatically Sales Order should be created in the Target System through PI,
                   I have used Message Mapping which is working fine for single Customer and Vendor,
                   For Multiple Customers and Vendors i am using one ZTABLE, Only Message Mapping is not  sufficient to my requirement.
                  Now i am using both Message Mapping and   ABAP Mapping  at a time in Interface Mapping. I created the class and                done  the   development., whene  i run the scenario i am getting the error as below,
*<SAP:Stack>Error in mapping program ZCL_SD_IDTO_POSO (type SAP-ABAP, kernel error ID UNCAUGHT_EXCEPTION) An exception with the type CX_SY_REF_IS_INITIAL occurred, but was neither handled locally, nor declared in a RAISING clause Dereferencing of the NULL reference</SAP:Stack>*
  *<SAP:Retry>M</SAP:Retry>*
  *</SAP:Error>* 
Please let me know.
Best Regards
Vamsi

Have u seen the ABAP mapping guide?
Refer this series to the ABAP mapping section.https:///people/sravya.talanki2/blog/2006/12/26/aspirant-to-learn-sap-xiyou-won-the-jackpot-if-you-read-this-part-ii
It will be very handy and useful.

Similar Messages

  • [ABAP Mapping] Only with ABAP-Objects?

    Hi,
    found <a href="http://https://www.sdn.sap.comhttp://www.sdn.sap.comhttp://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/5c46ab90-0201-0010-42bd-9d0302591383">this how-to</a> that describes an ABAP mapping in SAP XI.
    Is ABAP mapping only possible with ABAP Objects? Do I have to use
    the StreamFactory class? Is there an alternative way to do such a mapping?
    Does anyone have another example for ABAP mapping?
    Thanks
    chris

    Hi Christian,
    usually you need that only for special cases. It is not so easy...
    You can find a simple example at my weblog <a href="/people/udo.martens/blog/2006/08/23/comparing-performance-of-mapping-programs Performance of Mapping Programs</a>. The same mapping is over there with other mapping kinds; as you see, ABAP seems to be most complex, he, he. One or two days, and you get it
    frohes Basteln,
    Udo

  • Error in codepage mapping for source system. Error

    Hi BW Experts,
    I am facing following error:
    Error message: Error in codepage mapping for source system. Error text:
    Details: Inbound Processing ( 1000  Records ) : Errors occurred
                Error in codepage mapping for source system. Error text:
                Update PSA ( 0 Records posted ) : Missing messages
    I repeated the delta working and everything fine.
    Does anybody know why this error occurs?

    Run rsa13 (for bi 7.0) find your source system which one you are using for data transfer and double  click on it and find special options there select  the optioned i mentioned already.
    Please search SDN you can fin threads related to this thread
    if not let me know.
    Regards.

  • Error in codepage mapping for source system. Error text:

    guyz,
    im facing the below issue in prod.
    Error in codepage mapping for source system. Error text:
    Message no. RSDS_ACCESS013
    Collection in source system ended
    Error message during processing in BI
    Diagnosis
    An error occurred in BI while processing the data. The error is documented in an error message.
    System Response
    A caller 01, 02 or equal to or greater than 20 contains an error meesage.
    Further analysis:
    The error message(s) was (were) sent by:
    Inbound Processing
    Procedure
    Check the error message (pushbutton below the text).
    Select the message in the message dialog box, and look at the long text for further information.
    Follow the instructions in the message.
    need your guidance,
    cheerz,
    raps.
    Edited by: raps on Mar 1, 2012 9:39 AM

    Hi ,
    Kindly go throught the following threads for your issue resolution::
    Error in code page mapping for Source System
    Erroe in source system
    Regards,
    Arpit

  • Predelivered ABAP Mapping by SAP (I dont want to go from scatch)

    Hi everybody,
    I have to code a ABAP Mapping.
    Is there somting predelivered by SAP?
    What is the name of the class?
    Thanks
    Regards Mario

    Hi,
    There is no such ABAP mapping code already delivered with XI.
    You have to code it in transaction SE24.
    U can go thru the links :-
    1.     How to u2026 Use ABAP Mapping in XI 3.0
    http://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/5c46ab90-0201-0010-42bd-9d0302591383
    2.     iXML ABAP Objects Jumpstart
    http://help.sap.com/saphelp_nw04/helpdata/en/86/8280ba12d511d5991b00508b6b8b11/frameset.htm
    3.     Testing ABAP Mapping
    Testing ABAP Mapping
    Regards,
    Chandra

  • Error While converting xml to sap abap string.

    Hi Experts,
    As i am doing an cross Application from SAP to .Net and vice versa.I am receiving an xml from .Net and it should be converted to ABAP string Using the following function module   SMUM_XML_PARSE 
    And the following string i am receiving from .net
    <Root><qApprovalInfo><RequesterId>xxxx</RequesterId><RequesterName>xxx</RequesterName><ApproverId>xxxx</ApproverId><ApproverLevel>1</ApproverLevel><PendingApprovalId>0200169911</PendingApprovalId><CreatedDate>20/07/2011</CreatedDate><CreatedBy>xx</CreatedBy><ModifiedDate>2011-07-20 16:45</ModifiedDate><ModifiedBy>xxxx</ModifiedBy><ApplicationCode>EPAY</ApplicationCode><WorkFlowCode>EPX</WorkFlowCode><ApprovalStatus>APPROVED</ApprovalStatus><ActionComments><![CDATA[APPROVED(through  Desktop)]]></ActionComments><Mode>CREATE</Mode><ActionSource>DESKTOP</ActionSource></qApprovalInfo><qApprovalHidden><Approverl>40002664</Approver><EmployeeId>40016515</EmployeeId></qApprovalHidden></Root>
    In this xml i am getting all the values except the <ActionComments><![CDATA[APPROVED(through Desktop)]]></ActionComments>
    is their any way to convert that CDATA value?..
    have anybody come across the following issue ?...
    can anybody provide the solution for this?.
    Edited by: basavaraj.p on Aug 29, 2011 10:54 AM

    Hi,
    SMUM_XML_PARSE is a simplified, unreleased and undocumented version of the powerful, released and documented iXML
    If you look at the GET_ELEMENT subroutine in that function module, you'll see that the nodes of type CO_NODE_CDATA_SECTION are simply ignored.
    The simpliest thing for you, maybe, is to duplicate the code of SMUM_XML_PARSE (as it is rather easy to handle), and add a section to GET_ELEMENT. You'll have also to use IF_IXML_CDATA_SECTION interface and ixml_iid_cdata_section constant.
    Documentation is here: [SAP Library: Interface if_ixml_cdata_section|http://help.sap.com/saphelp_nw70/helpdata/en/bb/576658dca511d4990b00508b6b8b11/frameset.htm ]
    Best regards,
    Sandra

  • Advantages of netweaver(webdynpro abap) comparing to sap(abap

    plz tell me the advantages of netweaver(webdynpro abap)comparing sap

    Hi,
    Broken link removed
    Also, I have the official Web Dynpro for ABAP documentation. Please let me know if I should send it to you.
    Hope that the following also helps you.
    Web Dynpro for ABAP (WD4A, WDA) is the SAP standard UI technology for developing Web
    applications in the ABAP environment. It consists of a runtime environment and a graphical
    development environment with special Web Dynpro tools that are integrated in the ABAP
    Workbench (SE80).
    Web Dynpro offers the following advantages for application developers:
    ● The use of declarative and graphical tools significantly reduces the implementation
    effort
    ● Web Dynpro supports a structured design process
    ● Strict separation between layout and business data
    ● Reuse and better maintainability by using components
    ● The layout and navigation is easily changed using the Web Dynpro tools
    ● Stateful applications are supported – that is, if the page is changed and the required
    data remains intact so that you can access it at any time throughout the entire
    application context.
    Note that stateless applications are not possible.
    ● Automatic data transport using data binding
    ● Automatic input check
    ● Automatic operation of the Web Dynpro application using the keyboard
    ● User interface accessibility is supported
    ● Full integration in the reliable ABAP development environment
    Web Dynpro Architecture
    Definition
    Web Dynpro is the SAP NetWeaver programming model for user interfaces (UIs).
    The Web Dynpro model is based on the Model View Controller paradigm, and has the
    following features that build on the classic dynpro model:
    ● Clear separation of business logic and display logic
    ● Uniform metamodel for all types of user interfaces
    ● Execution on a number of client platforms.
    ● Extensive platform independence of interfaces
    Structure
    Metamodel Concept
    Web Dynpro provides support for developing Web representation of a business application.
    You use specific tools to describe the properties of a Web Dynpro application in the form of
    Web Dynpro metadata. The necessary source code is then generated automatically and
    executed at runtime. In addition to the events offered by the framework, you can also define
    your own events for a Web Dynpro application. However, the event handling must always be
    programmed in separate source code areas which are executed automatically when the event
    is triggered at runtime.
    In Web Dynpro, each user interface is always made up of the same basic elements. These
    elements of the metamodel can be statically declared using Web Dynpro tools.
    It is also possible to implement elements of the metamodel at runtime and to change them or
    reintegrate them at runtime. Using these implementations, you can make any changes or
    enhancements to a user interface that has been created by declarative methods by
    generating new interface structures at runtime.
    This means that you can combine declarative processes and the implementation of source
    code.
    Graphical Development Tools
    To support this declarative concept, both the SAP NetWeaver Developer Studio and the
    ABAP Workbench contain a range of Web Dynpro tools. You can therefore generate a large
    proportion of a Web Dynpro application using the tools provided, without having to create your
    own source code. This applies to the following parts of the application:
    ● Data flow between the front end and back end
    ● Layout of the user interface
    ● Properties of user interface elements
    The Web Dynpro tools enable you to create source text areas manually within generated
    source texts. These areas are not changed if the source code is regenerated.
    Separation of Business and Application Logic
    Using Web Dynpro enables a clear separation of business logic and display logic. A Web
    Dynpro application runs on the front end and has local or remote access to the back end
    system via a service. This means that the display logic is contained in the Web Dynpro
    application, while the business logic and the persistence of the business objects run in the
    back end system. The following options are currently available for connecting Web Dynpro
    applications and the back-end system:
    ● An interface generated using adaptive RFC, through which BAPIs of an SAP system
    can be called
    ● An interface for calling Web services
    ● A self-generated interface
    The source code required for connecting the Web Dynpro application can be generated
    from a UML definition of the Web Dynpro interface. A UML definition can be imported
    into the Web Dynpro tools as an XML file.
    Conversion of the Model-View-Controller
    Conversion of the Model-View-Controller Programming Model
    Every Web Dynpro application is structured according to the Model View Controller
    programming model:
    ● The model forms the interface to the back end system and thus enables the
    Web Dynpro application access to data.
    ● The view is responsible for the representation of the data in the browser.
    ● The controller lies between the view and the model. The controller formats
    the model data to be displayed in the view, processes the user entries made by the
    user, and returns them to the model.
    Web Dynpro ABAP Demonstration Videos
    Regards,
    Sree
    Edited by: Jason Lax on Feb 2, 2012 4:44 PM

  • Interface SAP/ABAP-Host - Non SAP/ABAP Host

    Hi experts,
    I need to define an interface technoloty between an ABAP-host and a Non-ABAP host.
    I know, that non-abap hosts are able to call RFC-Function Modules of the ABAP-host and that I can use this method to exchange data between the systems. This means, the non-abap host starts the action.
    But I don't know, how I can do it on the other way, so that the ABAP-host starts the action.
    So how can I call a function/program on the non-abap host out of SAP?
    Do I need to define this as an external program call in SM59?
    And if so, how does the syntax needs to be look-like, which I need to implement in ABAP.
    Is it an normal RFC-FM which has the destination of the SM59?
    Kind regards and thank you for every tip.

    Hi Christian,
                        SUP i.e Sybase is the interface which is used to connect non SAP to SAP system via RFC-FM. It does not require to do RFC settings through SM59.
    Regards,
    Shahezad

  • 500 Internal Server Error for ArchiveLink Repository type SAP System Database

    Hi, All!
    I made all settings by SAP Note 595563 "Database storage for ArchiveLink" and set new repository for document type HRICOLFOTO (in view TOAOM_C).
    When I try upload photo by tr.OAOH or open repository in tr.CSADMIN I get error "500 Internal Server Error".
    When I see to the 3rd level ICM-log (tr.SMICM) I see full html response (in attached file).
    Is there any idea?
    Best regards,
    Valeriy.

    Hi Valeriy,
    Could you perform these steps and check the result
    Start transaction SICF.
    Go to "External aliases".
    Select "default_host".
    Select Create.
    External alias: /sap/bc/contentserver
    Description: HTTP Content Server interface
    Fill anonymous logon data.
    Select the target element /default_host/sap/bc/contentserver.
    Save your entries.
    Hope this helps.
    Regards,
    Deepak Kori

  • IDOC-XI-FILE Scenario: Error in ABAP Mapping

    Dear All,
    I am working on IDOC-XI-Flat FIle scenario in which I am using ABAP Mapping as per document "How To Convert an IDoc-XML
    structure to a flat file and vice versa in XI 3.0".
    I created one customized Idoc for this. The Idoc is reacing XI but its flat file is not getting created. Its giving me following error:
    <SAP:Stack>Error in mapping program Z_ABAP_MAPPING_PACKING_LIST (type SAP-ABAP, kernel error ID UNCAUGHT_EXCEPTION) An exception with the type CX_SY_REF_IS_INITIAL occurred, but was neither handled locally, nor declared in a RAISING clause Dereferencing of the NULL reference.</SAP:Stack>
      <SAP:Retry>M</SAP:Retry>
    I have also gone thru threads posted for the same topic earlier but still I am not been to resolve this error.
    Please help me out in resolving this error.
    Regards,
    N.Jain

    HI,
       Log saying that, u have problem in the mapping program.
      i.e Z_ABAP_MAPPING_PACKING_LIST
       the problem is due declaration of data.
       i hope that, you have some methods.
       those are declared under intialization section in mapping program.
      please use start of selection before the method.
    other wise, it will come under intilization section.
    warm regards
    mahesh.

  • Error the class for ABAP mapping doesnt exist

    hi PI gurus,
    i faced a probleme when i was trying to call a second Mapping which type is ABAp after another one which type is Message Mapping, why i m doing that because i was trying to folow the step by step of michal :
    http://www.sdn.sap.com/irj/scn/weblogs;jsessionid=(J2EE3417100)ID0279207250DB01347930475897169967End?blog=/pub/wlg/6398
    but the problem is i get the error that the class doesnt exist but i m sure that the class exist and i cheked in se24.
    do you have any idea ????
      <SAP:Stack>Error in mapping program Z_ABAP_MAPPING_EXCEPTION_RS (type SAP-ABAP, kernel error ID CREATE_OBJECT_CLASS_NOT_FOUND) The object could not be created: The class Z_ABAP_MAPPING_EXCEPTION_RS does not exist.</SAP:Stack>
    thanx.

    Check this thread
    [Re: SOP Confituration- Maintain Copy Profiles version A00 not maintained   |SOP Confituration- Maintain Copy Profiles version A00 not maintained;
    thanks
    G. Lakshmipathi

  • ABAP Mapping Programm error  Urgent

    I am getting mapping error in ABAP Mapping programm. plz help me how to solve
    <?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
    - <!--
    Request Message Mapping
      -->
    - <SAP:Error xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="">
      <SAP:Category>Application</SAP:Category>
      <SAP:Code area="MAPPING">APPLICATION_PROGRAM_ERROR</SAP:Code>
      <SAP:P1>Z_HBS_PAYROLL_MAPPING</SAP:P1>
      <SAP:P2>SAP-ABAP</SAP:P2>
      <SAP:P3>UNCAUGHT_EXCEPTION</SAP:P3>
      <SAP:P4>Program Z_HBS_PAYROLL_MAPPING=========CP Include Z_HBS_PAYROLL_MAPPING=========CM001 Line 1</SAP:P4>
      <SAP:AdditionalText />
      <SAP:ApplicationFaultMessage namespace="" />
      <SAP:Stack>Error in mapping program Z_HBS_PAYROLL_MAPPING (type SAP-ABAP, kernel error ID UNCAUGHT_EXCEPTION) An exception with the type CX_SY_REF_IS_INITIAL occurred, but was neither handled locally, nor declared in a RAISING clause Dereferencing of the NULL reference</SAP:Stack>
      <SAP:Retry>M</SAP:Retry>
      </SAP:Error>

    Hi,
    I think this exception you need to catch it in the ABAP..
    This may help u- http://help.sap.com/saphelp_47x200/helpdata/en/55/bff20efe8c11d4b54a006094b9456f/content.htm
    just cross verify with this guide-
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/e3ead790-0201-0010-64bb-9e4d67a466b4
    Regards,
    moorthy

  • ABAP MAPPING : Getting An Error

    hi all
    i am using a scenario where i am sending data from r/3(prog)>xi>R/3(RFC).
    in between i am using ABAP MAPPING
    i am getting an error:
    ERROR:  "" MP: Exception caught with cause com.sap.aii.af.ra.ms.api.RecoverableException: java.lang.StringIndexOutOfBoundsException: String index out of range: -7: com.sap.aii.af.rfc.afcommunication.RfcAFWException: java.lang.StringIndexOutOfBoundsException: String index out of range: -7""
    the ABAP MAPPING which i am using:
    METHOD IF_MAPPING~EXECUTE.
      BREAK-POINT.
      * initialize iXML
      TYPE-POOLS: IXML.
      TYPE-POOLS: IXML.
      DATA: L_IXML TYPE REF TO IF_IXML.
    *creating the Interface by calling the create method in class C_IXML
      CALL METHOD CL_IXML=>CREATE
    EXPORTING
       TYPE   = 0
        RECEIVING
          RVAL   = L_IXML.
    create stream factory
      DATA: STREAMFACTORY TYPE REF TO IF_IXML_STREAM_FACTORY.
      CALL METHOD L_IXML->CREATE_STREAM_FACTORY
        RECEIVING
          RVAL = STREAMFACTORY.
    create input stream
      DATA: ISTREAM TYPE REF TO IF_IXML_ISTREAM.
      CALL METHOD STREAMFACTORY->CREATE_ISTREAM_XSTRING
        EXPORTING
          STRING = SOURCE
        RECEIVING
          RVAL   = ISTREAM.
    *This iXML factory can create an empty XML document object named IDOCUMENT.
    initialize input document
      DATA:  IDOCUMENT TYPE REF TO IF_IXML_DOCUMENT.
      CALL METHOD L_IXML->CREATE_DOCUMENT
        RECEIVING
          RVAL = IDOCUMENT.
    parse input document
      DATA: IPARSER TYPE REF TO IF_IXML_PARSER.
      CALL METHOD L_IXML->CREATE_PARSER
        EXPORTING
          DOCUMENT       = IDOCUMENT
          ISTREAM        = ISTREAM
          STREAM_FACTORY = STREAMFACTORY
        RECEIVING
          RVAL           = IPARSER.
      IPARSER->PARSE( ).
      DATA: ROOT TYPE REF TO IF_IXML_ELEMENT.
    get message content of tag
      DATA: INCODE  TYPE REF TO IF_IXML_NODE_COLLECTION,
            INCODE1 TYPE REF TO IF_IXML_NODE_COLLECTION,
            INCODE2 TYPE REF TO IF_IXML_NODE_COLLECTION,
            INCODE0  TYPE REF TO IF_IXML_NODE_COLLECTION.
      CALL METHOD IDOCUMENT->GET_ELEMENTS_BY_TAG_NAME
        EXPORTING
         DEPTH     = 0
          NAME      = 'MANDT'
         NAMESPACE = ''
        RECEIVING
          RVAL      = INCODE0 .
      CALL METHOD IDOCUMENT->GET_ELEMENTS_BY_TAG_NAME
      EXPORTING
         DEPTH     = 0
        NAME      = 'EMPNO'
         NAMESPACE = ''
      RECEIVING
        RVAL      = INCODE.
      CALL METHOD IDOCUMENT->GET_ELEMENTS_BY_TAG_NAME
    EXPORTING
         DEPTH     = 0
    NAME      = 'EMPNAME'
         NAMESPACE = ''
    RECEIVING
    RVAL      = INCODE1.
      CALL METHOD IDOCUMENT->GET_ELEMENTS_BY_TAG_NAME
    EXPORTING
         DEPTH     = 0
    NAME      = 'DEPARTMENTNAME'
         NAMESPACE = ''
    RECEIVING
    RVAL      = INCODE2.
      DATA: URI TYPE STRING.
      URI = 'urn:sap-com:document:sap:rfc:functions'.
    * build up output document =============================================
    create output document
      DATA: ODOCUMENT TYPE REF TO IF_IXML_DOCUMENT.
      CALL METHOD L_IXML->CREATE_DOCUMENT
        RECEIVING
          RVAL = ODOCUMENT.
      DATA: RET_VALUE TYPE I.
    *At this point you can add the nodes (elements, attributes) into the document. First you have to declare the root element node.
      DATA: L_ELEMENT_ROOT TYPE REF TO IF_IXML_ELEMENT.
      CALL METHOD ODOCUMENT->CREATE_ELEMENT_NS
        EXPORTING
          NAME   = 'ZTEST1'
          PREFIX = 'ns1'
          URI    = 'urn:sap-com:document:sap:rfc:functions'
        RECEIVING
          RVAL   = L_ELEMENT_ROOT.
      DATA: L_ELEMENT_NODE TYPE REF TO IF_IXML_ELEMENT.
      CALL METHOD ODOCUMENT->CREATE_SIMPLE_ELEMENT
        EXPORTING
          NAME      = 'ZTEST1'
         NAMESPACE = 'xmlns ns1 urn:sap-com:document:sap:rfc:functions'
          PARENT     = ODOCUMENT
       VALUE     = '?xml version="1.0" encoding="UTF-8"?'
        RECEIVING
          RVAL      = L_ELEMENT_ROOT.
      DATA: ATTRIBUTE TYPE REF TO IF_IXML_ATTRIBUTE.
      CALL METHOD ODOCUMENT->CREATE_ATTRIBUTE_NS
        EXPORTING
          NAME   = 'ZTEST1'
          PREFIX = 'xmlns'" ns1="urn:sap-com:document:sap:rfc:functions"'
          URI    = 'urn:sap-com:document:sap:rfc:functions'
        RECEIVING
          RVAL   = ATTRIBUTE.
      RET_VALUE = ODOCUMENT->SET_NAMESPACE_PREFIX(
    PREFIX = 'ns1').
      CALL METHOD ATTRIBUTE->SET_VALUE
        EXPORTING
          VALUE = URI
        RECEIVING
          RVAL  = RET_VALUE.
      CALL METHOD L_ELEMENT_ROOT->SET_ATTRIBUTE_NODE_NS
        EXPORTING
          NEW_ATTR = ATTRIBUTE
        RECEIVING
          RVAL     = RET_VALUE.
      DATA: NODE_LIST_COLLECTION TYPE REF TO IF_IXML_NODE_COLLECTION.
    add node to the output document
      DATA: OUTCODE0 TYPE REF TO IF_IXML_NODE.
      DATA: OUTCODE  TYPE REF TO IF_IXML_NODE.
      DATA: OUTCODE1 TYPE REF TO IF_IXML_NODE.
      DATA: OUTCODE2 TYPE REF TO IF_IXML_NODE.
      DATA: INDEX1 TYPE SY-INDEX.
      DATA: INDEX TYPE SY-INDEX.
      DATA IRC TYPE I.
      CALL METHOD IDOCUMENT->GET_ELEMENTS_BY_TAG_NAME
        EXPORTING
       DEPTH     = 0
          NAME      = 'MANDT'
       NAMESPACE = ''
        RECEIVING
          RVAL      =  NODE_LIST_COLLECTION.
      DATA: LENGTH TYPE I.
      CALL METHOD NODE_LIST_COLLECTION->GET_LENGTH
        RECEIVING
          RVAL = LENGTH.
      WHILE INDEX < LENGTH.
        CALL METHOD IDOCUMENT->CREATE_SIMPLE_ELEMENT
          EXPORTING
            NAME      = 'DATA'
       NAMESPACE = ''
            PARENT     = L_ELEMENT_ROOT
       VALUE     =
          RECEIVING
            RVAL      =  L_ELEMENT_NODE .
        CALL METHOD INCODE0->GET_ITEM
          EXPORTING
            INDEX = INDEX
          RECEIVING
            RVAL  = OUTCODE0.
        CALL METHOD INCODE->GET_ITEM
          EXPORTING
            INDEX = INDEX
          RECEIVING
            RVAL  = OUTCODE.
        CALL METHOD INCODE1->GET_ITEM
          EXPORTING
            INDEX = INDEX
          RECEIVING
            RVAL  = OUTCODE1.
        CALL METHOD INCODE2->GET_ITEM
          EXPORTING
            INDEX = INDEX
          RECEIVING
            RVAL  = OUTCODE2.
        CALL METHOD L_ELEMENT_NODE->APPEND_CHILD
          EXPORTING
            NEW_CHILD = OUTCODE0
          RECEIVING
            RVAL      = IRC.
        CALL METHOD L_ELEMENT_NODE->APPEND_CHILD
          EXPORTING
            NEW_CHILD = OUTCODE
          RECEIVING
            RVAL      = IRC.
        CALL METHOD L_ELEMENT_NODE->APPEND_CHILD
          EXPORTING
            NEW_CHILD = OUTCODE1
          RECEIVING
            RVAL      = IRC.
        CALL METHOD L_ELEMENT_NODE->APPEND_CHILD
          EXPORTING
            NEW_CHILD = OUTCODE2
          RECEIVING
            RVAL      = IRC.
        ADD 1 TO INDEX.
      ENDWHILE.
    render document ======================================================
    create output stream
      DATA: OSTREAM TYPE REF TO IF_IXML_OSTREAM.
      CALL METHOD STREAMFACTORY->CREATE_OSTREAM_XSTRING
        EXPORTING
          STRING = RESULT
        RECEIVING
          RVAL   = OSTREAM.
    DATA: IPARSER TYPE REF TO IF_IXML_PARSER.
      CALL METHOD L_IXML->CREATE_PARSER
        EXPORTING
          DOCUMENT       = ODOCUMENT
          ISTREAM        = ISTREAM
          STREAM_FACTORY = STREAMFACTORY
        RECEIVING
          RVAL           = IPARSER.
      IPARSER->PARSE( ).
    create renderer
      DATA: RENDERER TYPE REF TO IF_IXML_RENDERER.
      CALL METHOD L_IXML->CREATE_RENDERER
        EXPORTING
          DOCUMENT = ODOCUMENT
          OSTREAM  = OSTREAM
        RECEIVING
          RVAL     = RENDERER.
      IRC = RENDERER->RENDER( ).
    ENDMETHOD.
    plz help me out ASAP
    thnks
    kalyan

    hi
        all
    now the situation is that i am able to send the data to R/3,
    But in RWB-->MessageMonitoring ->version>Message Contents i am getting a error :
    *XML Parsing Error: not well-formed
    Location: http://aipid:50000/mdt/messagecontentservlet?attachment=0
    Line Number 1, Column 176:*
    <?xml version="1.0"?><ns1:ZTEST1 xmlns:ns1="urn:sap-com:document:sap:rfc:functions"><DATA><MANDT>210</MANDT><EMPNO>000000000023</EMPNO><EMPNAME>C</EMPNAME></DATA></ns1:ZTEST1 xmlns:ns1="urn:sap-com:document:sap:rfc:functions">
    it is not converted into XML ,the underline is the error which it is showing.
    it would be great if any one can figure it out what might be the cause of this error
    thanks
    kalyan

  • OPEN DATASET in ABAP MAPPING

    Hi Gurus
    I'm trying to use the statement OPEN DATASET into a  ABAP MAPPING but when I test in ID I get this error:
    <Trace level="1" type="T">Error in mapping program ZCL_FI_CFD_MEX (type SAP-ABAP, kernel error ID UNCAUGHT_EXCEPTION) </Trace>
    Also I've a ABAP program to test MAPPING and in debbuging time OPEN DATASET is everything OK.
    Can I use any ABAP statement in ABAP MAPPING?
    Thanks in advance.
    Carlos

    Hello Carlos,
    Please check exception handling implementation in your ABAP mapping - precisely speaking, handling of exceptions for OPEN DATASET. From error message you receive, it is seen that the exception is raised in OPEN DATASET and this exception is not handled. List of exceptions that can occur when calling OPEN DATASET is given below (taken from ABAP documentation):
    CX_SY_FILE_OPEN / DATASET_REOPEN
    CX_SY_CODEPAGE_CONVERTER_INIT / CONVT_CODEPAGE_INIT
    CX_SY_CONVERSION_CODEPAGE / CONVT_CODEPAGE
    CX_SY_FILE_AUTHORITY /OPEN_DATASET_NO_AUTHORITY, OPEN_PIPE_NO_AUTHORITY
    CX_SY_PIPES_NOT_SUPPORTED
    CX_SY_TOO_MANY_FILES / DATASET_TOO_MANY_FILES
    Non-catchable exception / DATASET_PIPE_POSITION
    Please let me know what exactly exception occurs so that more accurate analysis of the issue could be provided to you.
    Please also provide source code extract of the affected mapping program (the part where OPEN DATASET is called) if possible.
    Regards,
    Vadim

  • [ABAP Mapping] No output

    Hey,
    try to do a scenario like "How to use ABAP mapping in SAP XI 3.0", but got no output.
    Is it correct that we don't need a namespace for abap mapping? In the "How to" document the namespace field is empty, but in sxmb_moni he says:
    <b>  <SAP:AdditionalText>com.sap.aii.af.ra.ms.api.DeliveryException: error while processing the request to rfc-client: com.sap.aii.af.rfc.afcommunication.RfcAFWException: error while processing message to remote system:com.sap.aii.af.rfc.core.client.RfcClientException: could not get functionname from XML requst: com.sap.aii.af.rfc.RfcAdapterException: failed to read funtionname from XML document: missing namespace declaration(2)</SAP:AdditionalText> </b>
    But he takes the ABAP mapping, because in ABAP code I create following trace node:
    <i>  DATA: l_trace TYPE string.
      CONCATENATE 'Chris Sender Service = ' l_sender_service INTO l_trace.
      trace->trace( level = '1'
      message = l_trace ).</i>
    And in sxmb_moni he got it:
    <i><Trace level="1" type="T">Chris Sender Service =BS_Reisebuero2</Trace> </i>
    In sxi_mapping_test he writes, that the mapping was successful, but didn't create the output structure. Do I have a wrong ABAP code? Could it be, that I have a wrong append_child??
    Here it is (it equals the how to):
    <i>
    METHOD if_mapping~execute.
    initialize iXML
      TYPE-POOLS: ixml.
      CLASS cl_ixml DEFINITION LOAD.
    create main factory
      DATA: ixmlfactory TYPE REF TO if_ixml.
      ixmlfactory = cl_ixml=>create( ).
    create stream factory
      DATA: streamfactory TYPE REF TO if_ixml_stream_factory.
      streamfactory = ixmlfactory->create_stream_factory( ).
    create input stream
      DATA: istream TYPE REF TO if_ixml_istream.
      istream = streamfactory->create_istream_xstring( source ).
    parse input document =================================================
    initialize input document
      DATA: idocument TYPE REF TO if_ixml_document.
      idocument = ixmlfactory->create_document( ).
    parse input document
      DATA: iparser TYPE REF TO if_ixml_parser.
      iparser = ixmlfactory->create_parser( stream_factory = streamfactory
      istream = istream
      document = idocument ).
      iparser->parse( ).
    **********get source elements**********************************
    get message content of tag <carrid>
      DATA: carrid TYPE REF TO if_ixml_node_collection.
      carrid = idocument->get_elements_by_tag_name( 'carrid' ).
    get message content of tag <connid>
      DATA: connid TYPE REF TO if_ixml_node_collection.
      connid = idocument->get_elements_by_tag_name( 'connid' ).
    get message content of tag <fldate>
      DATA: fldate TYPE REF TO if_ixml_node_collection.
      fldate = idocument->get_elements_by_tag_name( 'fldate' ).
    ***********get meta datas****************************************
    get XI header data (here: "Sender Service")
      DATA: l_sender_service TYPE string.
      l_sender_service = param->get( if_mapping_param=>sender_service ).
    add trace (appears in message monitoring)
      DATA: l_trace TYPE string.
      CONCATENATE 'Chris Sender Service = ' l_sender_service INTO l_trace.
      trace->trace( level = '1'
      message = l_trace ).
    build up output document =============================================
    create output document
      DATA: odocument TYPE REF TO if_ixml_document.
      odocument = ixmlfactory->create_document( ).
    create element SXIDEMO_AIRL_FLIGHT_CHECKAVAIL and add it to the document
      DATA: sxidemo TYPE REF TO if_ixml_element.
      sxidemo = odocument->create_simple_element(
                           name = 'SXIDEMO_AIRL_FLIGHT_CHECKAVAIL_chris'
                           parent = odocument ).
    add FLIGHT_KEY node to the output document
      DATA: flight_key TYPE REF TO if_ixml_node.
      flight_key = carrid->get_item( index = 0 ).
      DATA irc TYPE i.
      irc = sxidemo->append_child( flight_key ).
    ***********add elements to output document *******************
    add carrid node to the output document
      DATA: outcode1 TYPE REF TO if_ixml_node.
      outcode1 = carrid->get_item( index = 0 ).
      irc = flight_key->append_child( outcode1 ).
    add connid node to the output document
      DATA: outcode2 TYPE REF TO if_ixml_node.
      outcode2 = connid->get_item( index = 0 ).
      irc = flight_key->append_child( outcode2 ).
    add fldate node to the output document
      DATA: outcode3 TYPE REF TO if_ixml_node.
      outcode3 = fldate->get_item( index = 0 ).
      irc = flight_key->append_child( outcode3 ).
    Testen einer manuellen eingabe
      outcode1 = odocument->create_simple_element(
                              name = 'passengerName'
                              value = 'Christian Riekenberg'
                              parent = flight_key ).
    render document ======================================================
    create output stream
      DATA: ostream TYPE REF TO if_ixml_ostream.
      ostream = streamfactory->create_ostream_xstring( result ).
    create renderer
      DATA: renderer TYPE REF TO if_ixml_renderer.
      renderer = ixmlfactory->create_renderer( ostream = ostream
      document = odocument ).
      irc = renderer->render( ).
    ENDMETHOD.
    </i>
    thanks
    chris
    Message was edited by:
            Christian Riekenberg

    Hi,
    I took a working scenario, that is runnable with java- and graphical mapping.
    Just change it to ABAP-Mapping.
    I just had forget to include the namespace into abap mapping. So the output has to look like:
    <ns1:SXIDEMO_AIRL_FLIGHT_CHECKAVAIL <b>xmlns:ns1="urn:sap-com:document:sap:rfc:functions"</b>>
    That was the missing namespace. Another problem was my created structure. I used the function append_child with a wrong input.
    Your tip, that I'm able to use the debugger in
    sxi_mapping test was great. So points for you!
    Message was edited by:
            Christian Riekenberg

Maybe you are looking for

  • IF-ELSE issue in Select Statement

    Hello, I have following query in SQL Server which I am trying to convert to Oracle 11g. IF '[Param.1]' = 'S' OR '[Param.1]' = 'T' THEN select * from ULQUEUE END IF But when I write the same query in Oracle, it gives error stating Invalid SQL Statemen

  • Weblogic 10.3.2   Error when deploying ear file

    Using WLS 10.3.2, wwhen activating changes, I obtain following errors: An error occurred during activation of changes, please see the log for details. Exception occured while downloading files [DeploymentService:290066]Error occurred while downloadin

  • How to format a pendrive in macbook pro

    how to format a pendrive in macbook pro

  • Itunes not syncing with any of my devices?

    Why does my itunes not recognise that any of my apple devices are plugged in? i have followed the steps on apple to solve this issue however it still doesnt let me sync with any of my devices... please help I have plugged in both my ipod and my ipad

  • Safari 4 Crashes Every Two Minutes

    Safari 4 ran fine until yesterday, for whatever reason Safari crashes even when just running in the background while I am using text edit. I don't recall installing any plugins. I tried uninstalling and installing and Safari and it still cant stop cr