JDBC Sender adapter - message split

All,
Scenario:
Oracle Stage table - PI - ECC or R3, (depending on a particular value the record goes to ECC or R3 to post a transaction).
After the record is picked, flag is updated and depending on posting the transaction on SAP, the flag is updated in the stage table.
With the JDBC sender adapter, multiple records are picked up depending on the select statement in the sender comm channel.
I have the following rek.
Now the message is in the AE, before the message enters IE, I would like to split the messages
This would help me in resubmitting the failed (failed to post the transaction) records.
Is there any way that I would be able to do it?
Any guidence...
reg

Hi Naveen,
An alternative way , instead of splitting the multiple record being picked up in a single poll,  you can control the number of records being picked. By using the following statement in the sender cc
SELECT * FROM ....   UPTO ROWS <  20
so that only 20 records are picked at a time. and resubmit the set of 20 in case it fails.
You can go for this method if it suits your requirement.
Regards,
Shamly

Similar Messages

  • JDBC Sender Adapter Message format

    I am somenone who is new to SAP PI so please help me out in the format of datatype for JDBC SENDER Adapter ?

    Hi Rajesh
    The source xml structure for JDBC adapter is like below
    <resultset>
    <row>
    <column-name1>column-value</ column-name1>
    <column-name2>column-value</ column-name2>
    <column-name3>column-value</ column-name3>
    </row>
    <row>
    <column-name1>column-value</ column-name1>
    <column-name2>column-value</ column-name2>
    <column-name3>column-value</ column-name3>
    </row>
    </resultset>
    Then in the sender JDBC adapter, write the select and update query
    SQL statement for query: SELECT * FROM table WHERE processed = 0;
    SQL statement for update: UPDATE table SET processed = 1 WHERE processed = 0;
    processed is the indicator in the database.
    Check this link for details
    https://help.sap.com/saphelp_nw04/helpdata/en/7e/5df96381ec72468a00815dd80f8b63/content.htm

  • JDBC Sender adapter is reading but then there isn't the message in SXMB_MON

    Hi,
    I have a JDBC to RFC async scenario. All configured.
    Now the JDBC Sender adapter is reading the database table and if I go to communication channel monitoring ther is a "Processing finished succefully" message and an message ID like that: "0e4fd3b0acba11ddb65e0002a5adffd2".
    But then I go to SXMB_MONI or message monitoring in RWB and there isn't a message to check...
    What's happening? How can I know what the JDBC adapter has read and why there isn't an error but there isn't a message?

    Hi
    Well u r that means no polling happening with u r Select statement
    may be format is correct i agree ,,can u able to get resultset using the Select staement running on SQL PLus ??
    check wether status flag is set right
    paste u r slect statement and update statement
    rgds
    srini

  • ** JDBC Sender Adapter support custom module ...?

    Hi friends,
    Does JDBC Sender Adapter support custom module ? If it is how it wil work ?
    Kind Regards,
    Jeg P.

    Hi Kulwinder,
    We want to separte the records (1:n) returned by JDBC sender adapter XML. ie. Split/Parse the records in XML and then send to BPM (one by one) instead of whole message . For that purpose, we want to write an adapter module.
    Is this possible ?
    Kind Regards,
    Jeg P.

  • JDBC sender adapter: Update before mapping

    Dear all,
    following scenario:
    in a database we have a field called "statpi". We pick all messages that have statpi =  0 and
    update the data record to statpi = 1 via UPDATE function in JDBC sender adapter.
    Every select statement is limited to 100 data records for each message in PI.
    But if one data record is wrong and the mapping failed, of course the complete mapping failed.
    My problem: The update function of the JDBC sender adapter has already updated the
    data records, although they didn't have been send to target system.
    What I need is following thing: The adapter should send the messages and after PI has mapped
    the message and send it to target system, the UPDATE command should be executed.
    In my opinion, this is only possible with BPM, but I am not familiar with Advanced mode in JDBC
    sender adapter and "Transaction isolation level". Is there any workaround for this?
    Thanks
    Regards
    Chris

    Stefan Grube wrote:>
    > What happens, when new values have entered db meanwhile?
    The job that change the DB will be fixed on a certain time. We need to configure
    Availability Time Planning to be sure, that we start our select at another time.

    > > In ideal case the data records are still in statpi=0 and get picked up after
    > > the database team has fixed the problem and the adapter polls again.
    >
    > If the flag is not set, the JDBC adapter would poll the same data again and again.
    The adapter should poll every hour. Of course we will have some errors before the
    support is able to fix this problem, but because of one message each hour this should
    not be the main problem.
    > - You could do following: pass the values with an error flag, so you can handle this in receiver application,
    I am using the function formatNumber for the field that could raised the error. But to chekc if I am able
    to do a workaround here and let the target system fix the error sounds like an interessting possibility.
    > - Do a split mapping and create a file where you drop any wrong lines
    Also interessting. You mean that all "good" record should be mapped to struc1 and the bad one to struc2.
    I am thinking of how to determine which record is wrong. Perhaps with an UDF that checks for this special
    error.
    > - Use XML validation in sender adpter, so the messages are not processed.
    You are full of good ideas. I am not using validation yet and the mentioned field is define as string, but that
    is changeable. A good possibility to check the new capability of 7.1.
    > - use a stored procedure in DB whee you check data quality to send out.
    not sure what this is, but I will discuss with DB team.

  • JDBC Sender Adapter - No Namespace found

    Hello
    I am currently using PI 7.1. The scenario is JDBC to ECC ABAP Client Proxy. When the JDBC Sender Adapter sends the data to the Integration Server, the root element does not contain the xmlns attribute. This root element is constructed from the Document Name of the JDBC Sender Adapter attribute.
    I am getting the following error:
      <?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">EXCEPTION_DURING_EXECUTE</SAP:Code>
      <SAP:P1>com/sap/xi/tf/_MM_HIS_Material_Consumption_</SAP:P1>
      <SAP:P2>com.sap.aii.mappingtool.tf7.IllegalInstanceExcepti</SAP:P2>
      <SAP:P3>on: Cannot create target element /ns0:MT_Material_</SAP:P3>
      <SAP:P4>Consumption_ECC/Material. Values missing in queue~</SAP:P4>
      <SAP:AdditionalText />
      <SAP:Stack>Runtime exception occurred during application mapping com/sap/xi/tf/_MM_HIS_Material_Consumption_; com.sap.aii.mappingtool.tf7.IllegalInstanceException: Cannot create target element /ns0:MT_Material_Consumption_ECC/Material. Values missing in queue~</SAP:Stack>
      <SAP:Retry>M</SAP:Retry>
      </SAP:Error>
    When I perform a test at RWB, the message gets posted successfully. Once posted, the payload of this message contains the xmlns attribute.
    Here is the root element from both the instances:
    From RWB:  <ns0:MT_Material_Consumption_JDBC xmlns:ns0="http://xxx.com/xxx/finance">
    From JDBC Adapter:  <ns0:MT_Material_Consumption_JDBC>
    Could you please let me know, what has to be done to obtain the xmlns in the sender payload?
    Thank you in advance.
    John Jeyaraj
    Edited by: John jeyaraj on Apr 7, 2011 8:22 AM

    Hi Hiren
    When I test the MM without the xmlns attribute, I get the following error:
    The prefix "ns0" for element "ns0:MT_Material_Consumption_JDBC" is not bound.
    When I add the xmlns attribute, the mapping is successful.
    Thanks
    John

  • JDBC Sender Adapter

    Hi everybody
    I have the following error in my JDBC to JDBC scenario; I  configured the JDBC sender adapter and receive the following message back. In the Configuration I set “Document Name” to MT_ScanningStatus:
      <?xml version="1.0" encoding="utf-8" ?>
    <MT_ScanningStatus>
    <row>
      <ScannerNb>1</ScannerNb>
      <Status>0</Status>
      </row>
    <row>
      <ScannerNb>2</ScannerNb>
      <Status>2</Status>
      </row>
    <row>
    <ScannerNb>3</ScannerNb>
      <Status>0</Status>
      </row>
    <row>
      <ScannerNb>4</ScannerNb>
      <Status>2</Status>
      </row>
      </MT_ScanningStatus>
    I defined the  corresponding datatype as follow:
    DT_ScanningStatus Complex Type
            row              Element 1...unbounded
              ScannerNb      Element 1
              STatus         Element 1
    In the following Mapping I tried to Map this structure to the Structure used to send an Update SQL Statement to the JDBC Receiver to update the same table.  A normal Test in the Mapping Tool runs fine but when I enter under source the above incoming Message from the JDBC Adapter I got the following error. I think the incoming message cannot be interpreted. Can someone support me? I read the documentation for the JDBC adapter and also a lot of weblogs and discussion threads. Maybe someone knows a weblog describing more detailed the sender adapter and how to handle the incoming Message!!
    Thanks in advance Oliver
    14:58:03 Start of test
    Compilation of MM_JDBC_to_JDBC_test successful
    Fatal Error: com.sap.engine.lib.xml.parser.ParserException: XML Declaration not allowed here.(:main:, row:1, col:8)
    com.sap.aii.utilxi.misc.api.BaseRuntimeException: Fatal Error: com.sap.engine.lib.xml.parser.ParserException: XML Declaration not allowed here.(:main:, row:1, col:8)
    at com.sap.aii.mappingtool.tf3.rt.xparser.MTSaxHandler.run(MTSaxHandler.java:130)
    at com.sap.aii.mappingtool.tf3.rt.xparser.XParser.run(XParser.java:68)
    Root Cause:
    com.sap.engine.lib.xml.parser.NestedSAXParserException: Fatal Error: com.sap.engine.lib.xml.parser.ParserException: XML Declaration not allowed here.(:main:, row:1, col:8)(:main:, row=1, col=8) -> com.sap.engine.lib.xml.parser.ParserException: XML Declaration not allowed here.(:main:, row:1, col:8)
    at com.sap.engine.lib.xml.parser.XMLParser.scanPI(XMLParser.java:2009)
    at com.sap.engine.lib.xml.parser.XMLParser.scanProlog(XMLParser.java:2657)
    at com.sap.engine.lib.xml.parser.XMLParser.scanDocument(XMLParser.java:2713)
    at com.sap.engine.lib.xml.parser.XMLParser.parse0(XMLParser.java:162)
    at com.sap.engine.lib.xml.parser.AbstractXMLParser.parseAndCatchException(AbstractXMLParser.java:132)
    at com.sap.engine.lib.xml.parser.AbstractXMLParser.parse(AbstractXMLParser.java:142)
    at com.sap.engine.lib.xml.parser.AbstractXMLParser.parse(AbstractXMLParser.java:245)
    at com.sap.engine.lib.xml.parser.Parser.parseWithoutSchemaValidationProcessing(Parser.java:276)
    at com.sap.engine.lib.xml.parser.Parser.parse(Parser.java:338)
    at com.sap.engine.lib.xml.parser.SAXParser.parse(SAXParser.java:125)
    at javax.xml.parsers.SAXParser.parse(SAXParser.java:345)
    at com.sap.aii.mappingtool.tf3.rt.xparser.MTSaxHandler.run(MTSaxHandler.java:128)
    at com.sap.aii.mappingtool.tf3.rt.xparser.XParser.run(XParser.java:68)
    at com.sap.engine.lib.xml.parser.SAXParser.parse(SAXParser.java:144)
    at javax.xml.parsers.SAXParser.parse(SAXParser.java:345)
    at com.sap.aii.mappingtool.tf3.rt.xparser.MTSaxHandler.run(MTSaxHandler.java:128)
    at com.sap.aii.mappingtool.tf3.rt.xparser.XParser.run(XParser.java:68)
    Caused by: com.sap.engine.lib.xml.parser.ParserException: XML Declaration not allowed here.(:main:, row:1, col:8)
    at com.sap.engine.lib.xml.parser.XMLParser.scanPI(XMLParser.java:2009)
    at com.sap.engine.lib.xml.parser.XMLParser.scanProlog(XMLParser.java:2657)
    at com.sap.engine.lib.xml.parser.XMLParser.scanDocument(XMLParser.java:2713)
    at com.sap.engine.lib.xml.parser.XMLParser.parse0(XMLParser.java:162)
    at com.sap.engine.lib.xml.parser.AbstractXMLParser.parseAndCatchException(AbstractXMLParser.java:132)
    at com.sap.engine.lib.xml.parser.AbstractXMLParser.parse(AbstractXMLParser.java:142)
    at com.sap.engine.lib.xml.parser.AbstractXMLParser.parse(AbstractXMLParser.java:245)
    at com.sap.engine.lib.xml.parser.Parser.parseWithoutSchemaValidationProcessing(Parser.java:276)
    at com.sap.engine.lib.xml.parser.Parser.parse(Parser.java:338)
    at com.sap.engine.lib.xml.parser.SAXParser.parse(SAXParser.java:125)
    ... 3 more
    Fatal Error: com.sap.engine.lib.xml.parser.ParserException: XML Declaration not allowed here.(:main:, row:1, col:8)

    Hi Oliver,
    >>>>source the above incoming Message from the JDBC Adapter I got the following error. I think the incoming message cannot be interpreted.
    do this:
    in the test tab try your mapping once more
    (the correct one)
    then save the source xml as file
    next compare this saved file with the one
    you get from the jdbc sender
    >>>>>Declaration not allowed here.(:main:, row:1, col:8)
    and compare the first lines in those two XML files
    are they the same?
    Regards,
    michal
    <a href="/people/michal.krawczyk2/blog/2005/06/28/xipi-faq-frequently-asked-questions"><b>XI / PI FAQ - Frequently Asked Questions</b></a>

  • PI 7.1 JDBC sender adapter huge load from DB select

    Hi,
    We have the problem that the JDBC sender adapter is selecting a huge amount of data from a Oracle DB. The Adapter seems to be able to cope the load but when sending to the integration server it causes problems. We found values to adjust but I dont think increasing them is a good solution.
    My question is:
    Is there any way to send the data in blocks with using the PI standard JDBC adapter ?
    Thank you and regards,
    Andreas

    Hi,
    You can use the below parameter in JDBC sender.
       Specify additional Parameter Names and Parameter Values in the table.
    Due to messages of large size it may cause issue
    Following are the parameters to be set in the table to limit the message size per polling:
    ●      msgLimit :
    ●      maxMsgSize :  SAP note 1253826.
    ●      maxRowSize : SAP note 1253826.
    Additional parameters are published in SAP Note 801367.
    Refer the link.
    Defining Additional Parameters in Advanced mode
    http://help.sap.com/saphelp_nw73/helpdata/en/7e/5df96381ec72468a00815dd80f8b63/content.htm

  • Problem with JDBC Sender adapter

    hi guys!
    I´ve problem in PI 7.0, with the JDBC Sender Adapter, execute select sentence and update status in Oracle database.
    In RWB Message Monitoring and SXMB_MONI I can't see any message.
    Someone have any idea how to fix it?
    Thanks in advance.

    Hi David,
    First check on the sender communication channel, if no data has been picked up by PI on channel,
    then check the configuration of channel in the ID, especially select query.
    If that is ok, then ask the sender application team(oracle database team) to run the query on their side
    and to check if they are getting any data.
    There could be the possibility of error in data also.
    -Supriya.

  • JDBC Sender Response Message as an XML SQL

    Hi All,
    I have a scenario as follows :
    JDBC Sender <-> XI (synchronous) <-> ABAP Proxy.
    I'm hoping that I can use XML SQL form at the JDBC Sender Response message, so I can update some fields at the database using the response message's data. But actually it's not working. Please advise whether it's applicable or not ? If it's not, is there any other way to do that ?
    Thanks in advance,
    Andy S

    Andy,
    Adding to the discussion here, JDBC sender adapter does not support Synchronous Processing .It supports only Asynch procesing and so, you would need a BPM inorder to update the database again with the ABAP Proxy response.
    You would have a sender jdbc adapter polling over the db and getting the data, --> a receiev step in the BPM receives the data.
    Next a send Synch Step makes the call to the ABAP Proxy and get the response.
    You map this response to a JDBC receiver adapters data format on the basis of the action you need and then use a send step with a receierv JDBC adapter to update the DB.
    Regards,
    Bhavesh

  • JDBC Sender Adapter Configuration

    Hi All,
       i want to know if we can configure JDBC sender adapter to run only when we ask it to.
    Normally what happens is tht the JDBC Sender Adapter polls the database at specified intervals, i dont want that. I only want it to poll the database when i get a file from RFC.
    Regards,
    Sumit

    Hi,
    Thank you.I had posted a similar questions a few dayz back and someone said that if we make the jdbc adapter synchronous it would solve our purpose, but it wont.
    Bhavesh i went thru ur blog in the mornin b4 postin d question..btw itz a nice blog
    Domenico : this is not what im looking for.
    Cheers,
    Sumit
    Message was edited by: Sumit Khetawat

  • JDBC Sender Adapter to Oracle Server

    Hi Friends,
    Iam using JDBC Sender Adapter to connect to Oracle Server. I have mentioned all the parameters in the Configuration(sender communication channel) correctly.My Adapter Monitoring in RWB shows a message that "Processing finished successfully"...But I cannot see the data in SXMB_MONI. I mean the data is not getting picked from the Database..I have worked on the similar scenario previously and it was working fine...
    I have specified the datatype structure correctly.
    resultset
    >row
    >>field1
    >>field2
    wat is the problem.
    regards,
    raju...

    Hi,
    Can you check the following,
    1. Check the SELECT query in your Sender JDBC adapter. Does it actually return any rows?
    2. The values enterd for Documentname and DocumentNamespace in your Sender JDBC adapter. You have to enter the name of the Datatype and the namespace in these fields.
    3.Have you enterd these details while doing the  adapter configuration,
    <b>jdbc:oracle:thin:@<IP adress>:<listener port>:<instance name (database name)>
    Driver oracle.jdbc.driver.OracleDriver</b>
    Regards,
    Bhavesh

  • JDBC Sender Adapter Threads and DB connections

    Hello,
    I have got a few questions regarding the behaviour of the JDBC sender adapter.
    Suppose I have configured a short polling intervall of 10 seconds. On the first poll a message is processed. How does the JDBC sender adapter behave when there is a second poll after 10 seconds and data is available? Does it wait until the first poll has been processed completely or does it start a second thread processing a second message in parallel? If the latter is true, would a second database connection be retrieved or would both threads share one database connection? What would happen if a large number of unprocessed threads were waiting?
    Kind regards,
    Heiko

    hi heiko,
    whether the first thread is successful or not automatically a new thread is created after the polling interval.if the previous thread is accessing a data the database would lock that one for theat thread so until the lock is released the other thread has to wait for it.so you can see the thread waiting in SAP WEb GUI.There you can see a green indicator on the status column corresponding to the service.
    so a new service is created after the pollling interval irrespective of the pevious service's result and it waits in the queue till its resource is otained.
    configuring sender jdbc to poll a databe is not an advisable one that too this short polling interval.this will increase the queue length and obviously cause performance issues...........

  • Update- statement in JDBC sender Adapter

    Hi ,
    I have a requirement where I am trying to fetch data from ODS based on some flag and immediately I want to update the flag status . So I used selected and update in JDBC sender adapter .
    But I have one question , in the small timeframe where  XI has done a select and just before  XI could  issue the update statement  if a new record is added to ODS . Then  that new record will also get updated though it wasnot selected in select statement .
    Can someone let me know how to overcome this problem ; as I want to make sure I update only those recrods which are selected in select statement ??
    Thanks & Regards,
    Suvarna

    Hi,
    Check out the following thread. It gives the exact answer to this question.
    JDBC Sender Update Query
    One of the replies in the above thread:
    I put in an OSS note asking this exact question with your specific example, and got a reply. I was referred to OSS note 0000831162, where it is explained very unambiguously that the SELECT and UPDATE queries are run in the same transaction.
    Regards,
    P.Venkat
    Message was edited by:
            Venkataramanan

  • JDBC Sender Adapter - NOT FETCHING RECORDS...

    Hello Experts,
    I know this was answered in a separate thread (JDBC Sender Adapter -  NOT FETCHING RECORDS -PROCESSING STARTED).
    However, my question is, Is there a way that we can be notified if a channel has stopped fetching records?
    or is there a reporting tool that can be used to check/monitor if a channel is not processing any messages?
    Thanks & Kregards,
    allar

    Hi Sreedhar,
    Thanks for your reply.
    These case is not being captured by our alert configuration because its not throwing any error.
    in the communication channel monitoring, we see only something like this..:
    3/16/09 8:25:19 PM Processing started
    3/16/09 8:34:20 PM Processing started
    3/16/09 8:33:55 PM Processing started
    3/16/09 8:32:54 PM Processing started
    but no error is being displayed nor sent.
    Also, there was a case that the channel just stopped fetching, even though everything is active.
    example log:
            3/12/09 8:32:54 PM Processing started
    We're looking for ways on how we can trap these scenarios as early as possible,  get us notified and   perform adapter-lock release when needed.
    Regards,
    allar

Maybe you are looking for

  • Orders cancelled

    I am very frustrated with the Bestbuy.com customer service at the moment. My local store is very convenient so for the past few years, the majority of my orders on the website have been for in-store pickup. On June 6th, 2014 I placed an order through

  • How to create web service in netweaver 7.0?

    Dear sir. Firstly I'm new in sap product, and needs your help. I downloaded netweaver 7.0 vmware on the sap site. 1. I want to create webservice on netweaver 7.0, and call this web service from other application. 2. If I create webservice on the anot

  • More abt xslt ...

    i have one more doubt pondering on.... ie creating a single xslt program template can be able to be used for various programming transformations in the future... or for each program we create we must create a xslt prog... for THE programs transformat

  • Best options for decent quality output?

    Hi all, I'm using a Canon HG10 shooting HD AVCHD. I am pretty pleased with the new archive facility as it's helping save space, and I'm debating whether to edit in 960x540 or 1920x1080. The 1080 footage looks way better onscreen (to my eye at least)

  • Camera Raw version compatible with LR 2.5 & PS CS3

    I had these two programs working happily, then earlier this year I upgraded Camera Raw to allow me to open some Canon 5D MII files in LR.  Now when I try to send a photo from LR to Photoshop (edit in Photoshop CS3), I get error dialogs.  (The message