Output from JDBC Adapter mapped to multiple message types

Hi!
I face to a problem with the message mapping.. I do select with the JDBC adapter. This statement selects one field of clob type and it already contains a message - XML document. Depending of the type of this message will be done the message mapping and also the target message type depends on this XML document type. But when u define message mapping, there must be always a target message type... But in the design time, I don't know the exact type! It is dynamic...
And not just with the message, the same situation is also with the target interface...
Any ideas how to solve this?
Thanx, Peter
Message was edited by: Peter Jarsunek

Hi,
I saw the weblog, but I think more important is the 'XI in action' mentioned in this one..
/people/ravikumar.allampallam/blog/2005/06/22/sap-xi-in-action
What I just can not understand from that blog is the step 2/4:
Receive XML file of any format and route to interface specific BPM..
How is it possible? On the output from the 1st BPM must be exact interface defined... How can different messages go out and than into the 2nd BPM?
Can you please write me, how the individual steps could follow after each other to achieve this?
Message was edited by: Peter Jarsunek

Similar Messages

  • Problem in JDBC Adapter Mapping

    Hi all,
    I am working on a scenario wherein i am trying to connect an ORACLE DB to SAP 4.7 system using XI 3.0 . I configured the JDBC Adapter and the JDBC adpter is picking up the message but i have a problem in JDBC adpter Mapping.
    The error message is like this:
    <!--  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">EXCEPTION_DURING_EXECUTE</SAP:Code>
      <SAP:P1>com/sap/xi/tf/_ORACLE_MSGMAP_</SAP:P1>
      <SAP:P2>com.sap.aii.utilxi.misc.api.BaseRuntimeException</SAP:P2>
      <SAP:P3>RuntimeException in Message-Mapping transformatio~</SAP:P3>
      <SAP:P4 />
      <SAP:AdditionalText />
      <SAP:ApplicationFaultMessage namespace="" />
      <SAP:Stack>During the application mapping com/sap/xi/tf/_ORACLE_MSGMAP_ a com.sap.aii.utilxi.misc.api.BaseRuntimeException was thrown: RuntimeException in Message-Mapping transformatio~</SAP:Stack>
      <SAP:Retry>M</SAP:Retry>
      </SAP:Error>
    How to map the "Resultset" from the Adapter to a target message? Can anybody throw some light on how to get the message from the JDBC adpter and map it to some other message format...Any documents regarding this ?
    Waitin for ur replies...
    Bye,
    Romit Shankar Arun.

    Hi,
    Does your other SDN post "Inserting data through JDBC adapter" refer to the same problem?
    I assume you use XMLSPY for creating XSDs.
    I used the XSD posted by you in the other forum thread and tried to generate the XML structure and it does not seem to generate the XML structure in the format required by the JDBC adapter.
    sample file generated from your XSD posted in the other forum thread:
    <?xml version="1.0" encoding="UTF-8"?>
    <resultset xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="C:\Untitled1.xsd">
         <row action="INSERT">
              <CUSTOMER_NUMBER>String</CUSTOMER_NUMBER>
              <COUNTRY_KEY>String</COUNTRY_KEY>
              <FIRST_NAME>String</FIRST_NAME>
              <LAST_NAME>String</LAST_NAME>
              <AUTHORIZATION_GROUP>String</AUTHORIZATION_GROUP>
              <INDUSTRY_KEY>String</INDUSTRY_KEY>
              <ACCOUNT_GROUP>String</ACCOUNT_GROUP>
              <INTIAL_CONTACT>String</INTIAL_CONTACT>
              <COMPANY_CODE>String</COMPANY_CODE>
              <CITY>String</CITY>
              <CITY_CODE>String</CITY_CODE>
              <COUNTRY_CODE>String</COUNTRY_CODE>
              <DISTRICT>String</DISTRICT>
              <FAX_NUMBER>String</FAX_NUMBER>
              <HOUSE_NUMBER>String</HOUSE_NUMBER>
              <POSTAL_CODE>String</POSTAL_CODE>
              <REGION>String</REGION>
              <TELEPHONE_NUMBER>String</TELEPHONE_NUMBER>
         </row>
    </resultset>
    Compare the above to the template i have mentioned.
    Hope this helps.
    Regards,
    Sridhar

  • Oracle Function call from JDBC Adapter

    Hi,
      Is it possible to call Custom Oracle Function from JDBC Adapter? 
    I know we can call stored procedure but I need to call Oracle function. Please explain how?
    Regards,
    Shweta.

    You'll need to provide a column alias for the function call:
    select func(val) as alias from dual

  • Where to see generated SQL statement from jdbc adapter?

    Hi everybody,
    where can I see the generated SQL statement from JDBC adapter?
    Regards Mario

    Yes and True lterally means the same, but alas XI does not understand literature..
    Just checked the note as well, as you are correct!
    Regards
    Bhavesh

  • Multiple message types for an idoc type

    Hi all,
    I created one custom idoc type with six segments. I heard that one idoc type can have any number of message types
    if it is so pls tell me how to assign these two message types for my idoc .
    i want to create multiple message types because i want to send same idoc type to diff legacy systems.
    My requirement is message type one is only for first three segments and message type two is for another three segments .
    The outbound program 1 for mess type 1 should fill fill the data for only first three segments and second outbound program corresponding to mess type 2 should fill the data for last three segments
    how should i design for my requirement. suppose if the idoc has two message types then it has two outbound programs?

    Hi Kunal,
    Below are my thoughts from a design perspective,
    My requirement is message type one is only for first three segments and message type two is for another three segments .
    The outbound program 1 for mess type 1 should fill fill the data for only first three segments and second outbound program corresponding to mess type 2 should fill the data for last three segments
    Before you look upon the no. of message types you need, i guess you need to look at the business requirement. Per your requirement you want to send send two sub sets of data. The first subset in the first 3 segments and other three segments for the second subset of data.
    Is the structure of the first subset of data similar to the second subset If not, better to create two IDOC Types. If they are similar, then create one IDOC Type with three segments and have two message types for each subset of data.
    For Ex: ORDERS05 is the IDOC type for Orders, this IDOC type provides capability to carry data related to any type of orders
    but the action on the data is facilitated by the message type like ORDERS for create, ORDCHG for change, ORDRSP for Order response etc.
    OR
    Are these two subsets of data related to each other, if yes understand the relation? If not related at all then you might be better of creating two separate IDOC Types.
    Like in the above example A purchase order is related to a sales order so you can use the same IDOC type, but in case of a order response and ASN that data sent is different and hence you will need different IDOC types (even though a SO is related to a DN).
    how should i design for my requirement. suppose if the idoc has two message types then it has two outbound programs?
    The above again depends on the how tightly/loosely coupled are the data sets, you can have just one program and have a simple case statement on the message types or have two different programs.
    You will also have to consider points like, if any of the subsets is more prone to more change in terms of the structure and associated business logic. If yes, then you might want to keep the programs separate to reduce work on regression testing etc.
    I am sure you will receive more inputs from the experts on the forum and the list of points to look for will get longer , so understand the requirement, dependencies and if you have any specific questions you could post it on the forum.
    Regards,
    Chen

  • Idocs multiple message types

    Hi all,
    I created one custom idoc type with six segments. I heard that one idoc type can have any number of message types
    if it is so pls tell me how to assign these two message types for my idoc .
    i want to create multiple message types because i want to send same idoc type to diff legacy systems.
    My requirement is message type one is only for first three segments  and message type two is for another three segments .
    The outbound program 1 for mess type 1 should fill fill the data for only first three segments and second outbound program corresponding to mess type 2 should fill the data for last three segments
    how should i design for my requirement. suppose if the idoc has two message types then it has two outbound programs?
    Edited by: kunal kakkar on May 16, 2011 10:21 AM
    Moderator message: duplicate post locked.
    Edited by: Thomas Zloch on May 16, 2011 12:39 PM

    COND_A01 is the IDoc to distribute the condition master data. Sales order (ORDERS05) is transactional data. It is not feasible to generate a master data IDoc from a sales document. Even if it was feasible, what would be the purpose? The master data hasn't changed, why would anyone want to send it again with every order?

  • Multiple message types for IDoc types

    Hi,
    can we assign multiple message types to IDoc Types?
    Is so How to make it
    Thanks in Advance....
    Regards
    Sravya

    Hi,
       For an IDOC Basic Type is the structure which defines the skeleton of the data transfer like what all fields can be present, how many times a field can appear, is it mandatory etc.
      A message type is a label used to identification.
    Message type come into picture because we can use the same IDOC basic type for any number of applications. So it becomes necessary that we need some other tag to identify & distinguish between all these. Message Type helps in this cause.
    Message type & Basic Type are linked in WE82.

  • Calling Stored Procedure from JDBC Adapter

    Hello,
    I am Updating a SQL Server Table using JDBC Adapter.
    Now I have multiple input rows and the procedure needs to be called for each set.
    Do I need to use multimapping for this or just generating multiple <b>Statement</b> node will solve?
    Also For this will there is any knows/ forseen problem (like Transaction handling) that I need to take care of?
    Thanks and Regards,
    Himadri
    Message was edited by:
            Himadri Chakraborty

    Himadri,
    You can just create multiple statement nodes in one message.
    I am not aware of any known or foreseen issues with this approach.
    Kind regads,
    Koen

  • Jdbc adapter error on confirmation message in message monitor (rwb)

    I have the scenario iDoc -> PI 7 - > jdbc (AS400 odbc driver).
    When I do INSERT statements, the data is stored in the Database and the RWB message monitoring shows status Successfull.
    However, for every insert, an other message shows up in the message monitoring with reversed Sender and Receiver (so it looks like a confirmation message is trying to find its way back to XI). This message first is is Status "Waiting", and after some time gets in Status "System Error".
    As I am not expecting any responses in my XI configuration (as I have no place to send them to), I want to stop these messages showing up in the Adapter Engine (as there will be many Error Status messages that are of no interest to me).
    How can I stop these messages, or what should I do in XI to process them (and dump them in my receiver determination). I have NO  BPM involved .

    Hi,
    For each open connection a entry is made j2ee stack.So when the it reaches to max and execption is thrown.
    In Jdbc adapter configuration -> advance mode -> Set -> Disconnect from the database after processing each message.
    Should solve the prob
    <b>Cheers,
    *RAJ*
    *REWARD POINTS IF FOUND USEFULL*</b>

  • JDBC adapter started but no message is created

    I am not able to read data through JDBC adapter.
    When we are starting our inbound JDBC adapter it get started and does not give any error
    but no message is created in XI.When we check status of adapters by clicking main menu it is red.
    Log of adapter shows.
    JDBC adapter initializd succesfully.
    JDBC adapter started.
    Process query select * from ??????.
    JDBC adapter processing complete.Restart for next processing.
    But no message is created in XI.
    Can the no of records be the cause of this problem.
    Any help appericiated

    Hi,
    You can change the logging and tracing level of the JDBC adapter using the trace and log properties.
    Some errors may appear in the adapter_x.log file (see traces from the main menu).
    Goodluck

  • Invoke stored procedure from JDBC Adapter

    Is there a tool that generates interfaces for stored procedure(ORACLE PL/SQL) like RFC or IDOC adapters?

    Hi Denis,
    I dont think there is any such tool.]
    To generate a Stored Procedure of your Oracle DB, all you will have to do in your <b>JDBC adapter configuration</b> is give the name of the Stored Procedure under <Table> and you will have to give "<b>execute</b>" as the value under action attribute.
    Just check this link. Hope it helps,
    http://help.sap.com/saphelp_nw04/helpdata/en/b0/676b3c255b1475e10000000a114084/content.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/4d/8c103e05df2e4b95cbcc68fed61705/content.htm
    Just check this blog of Sriram wherein a stored procedure of a MaxDB Database is called.
    /people/sriram.vasudevan3/blog/2005/02/14/calling-stored-procs-in-maxdb-using-sap-xi
    I have implemented a scenario which requires an Oracle stored procedure to be executed and so, if you do need any further info, let me know.
    Hope this info helps,
    Regards,
    Bhavesh

  • Sender File/FTP Adapter - Matching Input to Message Type

    Hi,
    I have a sender file/ftp adapter which is using content conversion to generate an XML document from the contents of a text file. This works fine and when I go into the SXI Monitor I can see the XML document I expect:
    <ns:DN_360BalanceExtract xmlns:ns="http://xxx">
    <ns:RN_360BalanceExtract xmlns:ns="http://xxx">
    <BalanceRecord>
       <SerialNo>xx10000780</SerialNo>
       <RegNo>A1</RegNo>
       <LocationTicketIssued>ALBERT ROAD SOUTH</LocationTicketIssued>
       <DateOfOffence>2008-02-15</DateOfOffence>
       <TimeOfOffence>13:38</TimeOfOffence>
       <OffenceDescription>xxx</OffenceDescription>
       <CurrentStateOfCase>RE-OPENED; CLOSED IN ERROR</CurrentStateOfCase>
       <OutstandingBalance>70.00</OutstandingBalance>
       </BalanceRecord
    <BalanceRecord>
       <SerialNo>xx90001245</SerialNo>
       <RegNo>S849KMR</RegNo>
       <LocationTicketIssued>ALBION PLACE</LocationTicketIssued>
       <DateOfOffence>2011-03-01</DateOfOffence>
       <TimeOfOffence>10:59</TimeOfOffence>
       <OffenceDescription>xxx1</OffenceDescription>
       <CurrentStateOfCase>xxx</CurrentStateOfCase>
       <OutstandingBalance>60.00</OutstandingBalance>
    </BalanceRecord>
    </ns:RN_360BalanceExtract>
    </ns:DN_360BalanceExtract>
    Having created the XML document from a text file I now wish to use the XML as input to a web service. This will of course involve mapping the XML document to a message in the inbound interface. Question is how do  associate the XML generated with a Message Type in the outbound interface. Do I need to make sure the Document or Recordset names match that of a Message Type ?
    Cheers,
    PaulC.

    Hi Paul
    The content conversion will create a document like that if you insert DN_360BalanceExtract as Document name, "http://xxx" as namespace.
    RN_360BalanceExtract will probably be your recordset, with its namespace.
    More information about content conversion on sender file adapter:
    http://help.sap.com/saphelp_nw04/helpdata/EN/ae/d03341771b4c0de10000000a1550b0/frameset.htm
    I'm not sure what you mean by bound. If you mean that PI has to execute mapping you created for that DN_360BalanceExtract message type, you need to associate DN_360BalanceExtract to a message interface and then create all configuration objects and choose that message mapping when you create the interface determination object.
    Regards,
    Giuseppe

  • Output medium 5 not working for invoice message type

    Dear all,
    we have an issue with output medium 5 for comercial invoices. We have defined current message type ZRD0 with this output medium (it still has other mediums assigned like 1) because when we create a comercial invoice we want to send the invoice automatically to customer mail as a pdf file.
    We have followed the instructions:
    -we have add this medium to message type and it has assigned exactly the same program and smartform as medium 1).
    - Communication strategy is already defined as it is being used for vendors mails.
    - Customer has e-mail address filled and my user in SU01 has a mail defined.
    Unfortunately mail is not being generated but spool is being generated?!? For vendors this output type is working fine, we are sending the PO to vendor's mail as pdf file and I don't understand why it's not working.
    Any ideas??
    thanks in advance,
    Raquel

    Hi Raquel
    Firstly In the output type ZRDO output type , check wheather the transmission medium has been checked or not. Secondly also check in VV32 with what transmission medium the record has been maintained.
    Finally also check in ZRDO output type wheather pdf file has been maintained or not
    Regards
    Srinath

  • Invalid Object when Calling Stored Procedure from JDBC Adapter

    JDBC Outbound adapter in XI 2.0 connected to SQL Server.  I've coded my mapping to format the XSL mapping properly but the Adapter appears to not be able to find the Stored Procedure.  Error message returned is "Invalid Object spStoredProcedureName".
    Does anybody have any clue as to what I'm missing???

    I know this is trivial, but did you use the "full" name of the SP as <schema>.<procname>???
    HTH

  • Interface Mapping with Multiple Message Mappings

    Hi My Scenario is
    File to Idoc.( Multiple records to Multiple idocs )
    Due to Complexity of Mapping I split the Mapping step into 2.
    My Source System does not provide Namspace when they are sending XML Data.
    When I try 2 mappings individually both Mappings works fine.
    However when I try test using Interface Mapping target messages are not generated.
    Since 2nd Mapping invoves Mapping Split its expecting extra tags as shown here in the Targert Message generated from Message Mapping 1.
    <i><ns0:Messages xmlns:ns0="http://sap.com/xi/XI/SplitAndMerge">
       <ns0:Message1></i>
    How can I solve this problem ?

    When I do Message Mapping:
    From message Mapping 1 target Produced is as follows:
    <?xml version="1.0" encoding="UTF-8"?>
    <ns0:CostMaintenanceXI xmlns:ns0="http://test.xxx.com">
    <CostMaintenanceXI>
    <CostMaintenanceXI>
    <Product>000000000000000023</Product>
    <Plant>1401</Plant>
    <Supplier>0000000001</Supplier>
    <ValidityFrom>20021212</ValidityFrom>
    <DIIndicator>ZFOB</DIIndicator>
    <COGAmount></COGAmount>
    <COGCurrency></COGCurrency>
    <FreightAmount></FreightAmount>
    <FreightCurrency></FreightCurrency>
    <MISCAmount></MISCAmount>
    <MISCCurrency></MISCCurrency>
    <SPAAmount></SPAAmount>
    <SPACurrency></SPACurrency>
    <LandedCaseCost></LandedCaseCost>
    <LandedCaseCurrency></LandedCaseCurrency>
    <FrontLinePrice></FrontLinePrice>
    <FrontLinePriceCurrency></FrontLinePriceCurrency>
    </CostMaintenanceXI>
    </CostMaintenanceXI>
    </ns0:CostMaintenanceXI>
    in 2nd Mapping I entered some details in the test tab and the generated source is as follows:
    <?xml version="1.0" encoding="UTF-8"?>
    <ns0:Messages xmlns:ns0="http://sap.com/xi/XI/SplitAndMerge">
       <ns0:Message1>
          <ns1:CostMaintenanceXI xmlns:ns1="http://test.xxx.com">
             <CostMaintenanceXI>
                <CostMaintenanceXI>
                   <Product>1</Product>
                   <Plant>1</Plant>
                   <Supplier>2</Supplier>
                   <ValidityFrom>12212122</ValidityFrom>
                   <FOBIndicator/>
                   <DIIndicator>ZFOD</DIIndicator>
                   <COGAmount>10</COGAmount>
                   <COGCurrency/>
                   <FreightAmount>10</FreightAmount>
                   <FreightCurrency/>
                   <MISCAmount>10</MISCAmount>
                   <MISCCurrency/>
                   <SPAAmount>10</SPAAmount>
                   <SPACurrency/>
                   <LandedCaseCost/>
                   <LandedCaseCurrency/>
                   <FrontLinePrice/>
                   <FrontLinePriceCurrency/>
                </CostMaintenanceXI>
             </CostMaintenanceXI>
          </ns1:CostMaintenanceXI>
       </ns0:Message1>
    </ns0:Messages>
    As you can see both of the above structures differs in xmlns. I dont see anything else weird.

Maybe you are looking for