Receiver JDBC structure and Mapping

Hello everyone,
Scenario - WS (async) -> PI 7.1 -> JDBC (sync) -> PI 7.1 -> WS (async)
My question is - In my request structure (from WS), I have a field "Transaction ID". This field is not present in the target DB, but when I get the response back from DB, I need to insert this transaction id in the response back to WS.
I am aware that there is an option in the request query (passing parameter and getting back the same value) and this can be achieved through XSL mapping. Can this same functionality be achieved through Graphical Mapping?
In other words, if I pass Transaction Id in my request query, can I get it back in the response? Just to remind, Transaction Id is not available in DB.
Any help / suggestion will be highly appreciated.
Thanks,
Abhi

Abhi,
Although your post is an old one, but since it is not yet closed, i assume that you are still working on this.
I believe you have a view from where you are doing the select. You can give it a try with the following query -
SELECT V1.<your other fields that you want to select>, V2.TRANSACTIONID,                        
          FROM <ViewName> V1,
                          (SELECT "TRANSACTIONID" AS TRANSACTIONID FROM DUAL) V2
          WHERE <Condition>
This will simply create a temporary view V2 for holding the transaction id, and it will pick the value that you are passing with each message and in the response to the SELECT, it will always bring back the Transaction Id that you passed.
I would recommend that you use an XSL Mapping for this. Hope this helps.
Regards,
Neetesh

Similar Messages

  • Problem to transform Flat file to Data Type Structurated and map to IDOC

    Hi all,
    I have a file to idoc scenario.
    The information is like this:
    1#!445#!AI12#!1#!20070214#!DVXXXXR#!201#!31GINHG876#!#!
    2#!#!ETC
    3#!000000000030008888#!#!3000#!#!10#!#!20070215
    4#!dades45#!b#!c#!d#!e#!f#!g
    5#!pos5
    where 1, 2, ... = key segments for the file adapter and #! are the field separator.
    this must go to a Data Type with substructures like this:
    (xml)
    .1
    ......2
    .3
    ......4
    ......5
    where 2 is inside 1 and 4-5 inside 3.
    The reason of this is we can get unbounded replays of 3/4/5 for one header.
    But XI reads the information like if all segments are headers.
    .1
    .2
    .3
    .4
    .5
    So the IDOC is bad created.
    Where is the issue?  At Message Mapping all substructures are mapped with his default and at TEST option it works fine.
    Thanks in advance for your help.
    best regards
    Message was edited by:
            Federico Martin
    Message was edited by:
            Federico Martin

    Dear people,
    according to license problems at client, it's impossible to get the convert agent.
    so now we come back to try to solve with normal mapping.
    the next step is try to convert it using 2 message mappings: dt (flat xml) to dt (structurated) and this one to the idoc.
    i suppose it can be done adding program at interface mapping.
    I created the no hiereachical Data Type for load the information and it's fine. But i am unable to get the first mapping OK, because XI has problems with unbounded segments.
    If you agreed and has time, i copy here the information and his structure.
    I receive (#! defines separation and key segment fields are 1,2,3,4,5):
    1#!445#!AH02#!1#!20070214#!DVPOSTER#!201#!31GINHGIN0#!#!
    2#!#!ETC
    3#!000000000030008888#!#!3000#!#!10#!#!20070215
    4#!dades45#!b#!c#!d#!e#!f#!g
    3#!000000000030008888#!#!3000#!#!10#!#!20070215
    3#!000000000030008888#!#!3000#!#!10#!#!20070215
    4#!dades45#!b#!c#!d#!e#!f#!g
    5#!pos5
    5#!pos5
    5#!pos5
    The destination must be:
    CHASE A
    1 (1..1)
    ....2 (1..1)
    3 (1..unbounded)
    ....4 (0..1)
    3 (1..unbounded)
    3 (1..unbounded)
    ....4 (0..1)
    5 (1..unbounded)
    5 (1..unbounded)
    5 (1..unbounded)
    CHASE B
    Or, in another case with 5 as child of 3 (like example in last mail)
    1#!445#!AH02#!1#!20070214#!DVPOSTER#!201#!31GINHGIN0#!#!
    2#!#!ETC
    3#!000000000030008888#!#!3000#!#!10#!#!20070215
    4#!dades45#!b#!c#!d#!e#!f#!g
    5#!pos5
    3#!000000000030008888#!#!3000#!#!10#!#!20070215
    5#!pos5
    3#!000000000030008888#!#!3000#!#!10#!#!20070215
    4#!dades45#!b#!c#!d#!e#!f#!g
    5#!pos5
    1 (1..1)
    ....2 (1..1)
    3 (1..unbounded)
    ....4 (0..1)
    ....5 (1..unbounded)
    3 (1..unbounded)
    ....5 (1..unbounded)
    3 (1..unbounded)
    ....4 (0..1)
    ....5 (1..unbounded)
    3 (1..unbounded)
    ....4 (0..1)
    ....5 (1..unbounded)
    Questions:
    How i do for map Data Type (no hierachical) -to-> Data Type (hierachical) and  Data Type (hierachical) -to-> IDOC? Is any loop or context object required?
    Thank you in advance for your help and sorry the long thread.

  • IDOC to JDBC, problem with the multiple line items structure and mapping

    Hi,
    I have a scenario where the ORDERS data need to update the SQL table. for the idoc which consists one line item its ok but for multiple line item its just updating one line item. In the destination side we have only one table for purchase order which consists of lineitem as a field.(no different tables for Header data and Line item data)
    Can anyone suggest me how to create a structure for target side and how to map them.
    Regards,
    CJ

    Hi Rajan,
    The table structure is
    [PO_DATE]
          ,[VENDOR_NO]      ,[PAYMENT_TERM]      ,[MATERIAL_CODE]      ,ORDERED_QTY]      ,RECEIVED_QTY]                                 
          ,[UOM]       ,[RATE]       ,[CURRENCY]       ,[PO_EXCRATE]       ,[TAX_CODE]       ,[BASE_VALUE]       ,[TAX_VALUE]
          ,[TOTAL_VALUE]       ,[ADVANCE_PAYAMT]       ,[TOTAL_QTY]        ,[SNO]       ,[POLINEITEM]
    Datatype structure:
    PO_XI_MT_ORDERS05 1-1
    STATEMENT   1-UNBOUN
      TABLENAME 1-1
        ACTION   optional
        TABLE    1-1
        ACCESS  1-1
           PO_NO   0-1
           PO_DATE 0-1
    Correct me if im wrong.
    Regards,
    CJ
    Edited by: kuncjy on May 5, 2011 11:32 AM

  • Receiver JDBC

    Hi
    the receiver JDBC structure
                                                                       occurence
    <statement1>   ----------------------------->                   1..unbound    or    1..1                               (1)
    <Table>            ----------------------------->                1..1 per statement always                             (2)
    <access>         ----------------------------->                  1..1 per statement always                             (3)
       <fld1></fld1>                                         
       <fld2></fld2>
    </access>
    <key> --------------------------------------->                   1..unbound    or  1..1                                       (4)                          
      <val1>
    </key>
    </statement1>
    <statement_response>  --------------->                        should be 1..unbound <b>if</b> statement request is 1..unbound (here statement1)
                                                                                    should be 1..1 <b>if</b> statement request is 1..1 (here statement1)                        (5)
    <row>                                       
    <row>
    </statement_response>
    -&gt; In which case we go for occurrence of statement (here statement1) = 1..unbound ??
    -&gt; if i need to select from one table do i need to use this as 1..unbound ?? Yes/No
    --&gt;each statement response (means all rows of that query) will come under row node with multiple occurrence Yes/No??
    --&gt;if i want to delete the rows from table where col= (value array) in this case i have to give key occurence as 1..unbound??Yes/NO
    --&gt;if i want to select all the data from one table..i no need any key..but as per sap help doc..if we dont specify the key the adapter will not accept and shows some error message...so i should some dummy key value..and need to compare with NEQ to NULL or space???
    --> If i want to select the data from JDBC using the receiver structure...can i declare all the field types as string in request and response structure..or it should match the data types of fields in data base..?? if so how it should be in select request and response structure??
    (1) (2) (3) (4) (5) are right or wrong..if wrong correct me..
    Thanks
    krish
    Edited by: murali krishna on Mar 24, 2010 5:30 PM

    Krish,
    Please see the below response
    Answer-1
    If you are selecting data from Different tables then you need to define Statement as 1.. Unbounded
    Answer- 2
    No. Since you are selecting data from one table - you can define it as 1..1
    Answer -3
    There will be only one Statement_Response per Statement. In other words if you have Multiple Statement in the Request , then you will have Multiple Statement(x)_Response
    So Under Statement_Response you will have Multiple Rows(for each record in the database) . YES - Row has to be 0.. Unbounded
    Answer- 4
    YES - You are correct
    Answer-5
    YES - you can define them all as a STRING. It shouldn't be a problem
    Hope it helps!
    Thanks!

  • Messages are in hold state due to one message at receiver JDBC adapter

    Hello,
    I am using a receiver JDBC adapter and trying to send an XML file which has an insert query to insert some data into the database i.e., Oracle 9i.
    Here at the receiver side due to one message (  which is in to be delivered state) all other messages are got hold and waiting for long time.
    I am getting the exceptions as this,
    JDBC Adapter processing failed with Error processing request in sax parser: Error when executing statement for table/stored proc. 'FSASMGR.XTBL_KL06_IINQUIRY' (structure 'REC01'): java.sql.SQLException: ORA-12899: value too large for column "FSASMGR"."XTBL_KL06_IINQUIRY"."CASE_TITLE" (actual: 81, maximum: 80)
    Exception caught when executing statement for table/stored proc. 'FSASMGR.XTBL_KL01_ISTAFF_MST' (structure 'REC1'):
    java.sql.SQLException: ORA-00001: unique constraint (FSASMGR.XTBL_KL01_ISTAFF_MST) violated
    Can anyone help me out in solving this issue.
    THanks,
    Soorya

    hi surya,
    jdbc channel tries a request for n number of times(no of rettries),if that request fails it will take up the following requests,its not like it will process a request forever.
    to be delivered will be resulting if reciever is down or network between XI and database server is bad.
    try to ping databse server from XI host system.
    if everything is fine then look at the channel configuration->advanced->no of retries of database transaction on sql server.
    just redue the count to 1 and recheck.
    Regards,
    rama Krishna

  • What are the Batch mode parameters for Receiver JDBC Adapter

    Hi All,
             Could some pls tell me how to set bacth mode in receiver JDBC adapter and what are its parameters and how to configure them. i beleive there is something like max count parameters etc..
    Regards,
    Xier

    Hi,
    Check this for more info
    http://help.sap.com/saphelp_nw04s/helpdata/en/64/ce4e886334ec4ea7c2712e11cc567c/frameset.htm
    Regards
    Seshagiri

  • UPDATE statement in Receiver JDBC adapter

    Hi all,
    I would like to use UPDATE statement in my receiver JDBC adapter and would like to know how this UPDATE statement works in following case.
    1) If i have 10 records to be updated in database, whether Commit happens at the end of all 10 records updation OR it will be for every record update?
    Regards

    Hi,
    Then let me construct my query this way...
    i have 10 records that needs to be updated to database, say For Ex: 7 records are updated successfully and 8th record has issue in updating the table.
    In this case i would like to ROLLBACK entire 10 records with out committing any thing.
    So if i use your 2nd option, it should perform as i expected right?
    Regards

  • Receiver JDBC: Error while doing the Deleting and Inserting new records

    Hi All,
              I am doing Idoc to JDBC scenario. In this I am collecting & bundling different type of Idocs and then sending to the JDBC receiver. My requirement is to delete the existing records in the database and insert the new records. I have configures as mentioned in the link
    Re: Combining DELETE and INSERT statements in JDBC receiver
    In the above link its shows for single mapping. In my scenario I am using multi mapping for collecting idocs in BPM. If I configured for normal mapping then it is working fine(Deleting existing records and Inserting new record). Whenever I am using multi mapping then I am getting following error in the receiver JDBC communication channel u201CError while parsing or executing XML-SQL document: Error processing request in sax parser: No 'action' attribute found in XML document (attribute "action" missing or wrong XML structure)u201D . Can you please tell me what might be the problem.
    Thanks & Regards,
    T.Purushotham

    Hi !
    check this out:
    JDBC - No 'action' attribute found in XML document - error
    JDBC receiver adapter: No 'action' attribute found in XML document
    It appears that the inbound payload (the one that is going from XI to the JDBC adapter) does not have the requiered tag to specify which SQL action to execute in the receiver system. Maybe the multimapping is not creating the desired output message format.
    Regards,
    Matias.

  • Structure for Receiver Jdbc adapter for multiple tables

    Hi,
    For Receiver JDBC adapter,Standard structure
    structure as
    Statement
       Tablename(TABLE1)
            Action
            Access
    Can i make a structure like
    Statement
         Tablename(TABLE1)
            Action
            Access
                fields....
         Tablename(TABLE2)
            Action
            Access
                fields......
    As i am using tables and I want to insert or update both of them or one based on some conditions.
    Will Insert be possible in single Statement or I have to create separate statements for each table. Can you please help me on this?
    Thanks in advance
    Best Regards,
    Harleen Kaur Chadha

    Hi Harleen,
            As already said by Dharanveer, all that you need to do is replicate the Statement level, so, istead of using this structure:
    Statement
    Tablename(TABLE1)
       Action
       Access
         fields....
    Tablename(TABLE2)
       Action
       Access
         fields......
            You will construct something like this:
    Statement1
    Tablename(TABLE1)
       Action
       Access
         fields....
    Statement2
    Tablename(TABLE2)
       Action
       Access
         fields......
           And this structure will be created in a single Data Type, that will be used to create a single Message Type, that you will use in your Message Mapping, and, the 2(or more tables that you need to manipulate) will be inserted/updated without problems using this approach.
           Thank you, and best regards,
           Wilson

  • Field mapping in transfer structure and communication structure

    Hi,
    I am able to see the mapping of BW field with R/3 field in the transfer structure.
    By the same time, in the communication structure the same BW field is there with out any mapping (Unmapped).
    Can any one advice what could be the problem. Thanks.
    Regards,
    Abhi.

    Hi Abhi
    In communication structure will not have any mapping, it is just the structure to communicate to Datatarget. Mapping between Source fields and BW fields is done at transfer rules and mapping btwn communication struture and Datatarget will be donein Update rules.
    Regards,
    Kiran.

  • Message protocol is different for sender and receiver JDBC

    In File adapter the message protocol can be either FTP or NFS for both sender as well as receiver. but for JDBC adapter the message protocol is JDBC and for receiver adapter the message protocol is XML SQL Format or native sql string only. Why this is different ? Why cant we use JDBC as message protocol for receiver also ?
    I thought JDBC is the message protocol for JDBC adapters irrespective of whether they are sender or receiver. Can someone throw light on this ?

    Hi,
    You can find more about JDBC scenario at following links:
    Configuring the Sender JDBC Adapter
    [http://help.sap.com/saphelp_nw04/helpdata/en/7e/5df96381ec72468a00815dd80f8b63/content.htm|http://help.sap.com/]
    [http://help.sap.com/saphelp_nw04/helpdata/en/1d/756b3c0d592c7fe10000000a11405a/content.htm|http://help.sap.com]
    Configuring the Receiver JDBC Adapter
    [http://help.sap.com/saphelp_nw2004s/helpdata/en/b0/676b3c255b1475e10000000a114084/content.htm|http://help.sap.com]
    [http://help.sap.com/saphelp_nw04/helpdata/en/64/ce4e886334ec4ea7c2712e11cc567c/content.htm|http://help.sap.com]
    [https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/6d36d51d-0b01-0010-b3aa-9cb313b63cf4|https://help.sap.com]
    Regards,

  • Datatype structure for receiver jdbc adapter

    what is the datatype structure while using a receiver jdbc adapter

    XML Document Format for the Message Protocol XML SQL Format
    You can modify one or more database tables by means of a message. Depending on the content of the message, you can either insert (INSERT), update (UPDATE), or delete (DELETE) the data. Results from queries (SELECT) can also be included in the response in XML format for synchronous messages. The XML document must have the following schema in this case:
    <root>
      <StatementName1>
    <dbTableName action=”UPDATE” | “UPDATE_INSERT”>
              <table>realDbTableName</table>
    <access>
    <col1>val1</col1>
    <col2>val2new</col2>
    </access>
    <key1>
    <col2>val2old</col2>
    <col4>val4</col4>
    </key1>
    <key2>
    <col2>val2old2</col2>
    </key2>
    </dbTableName>
      </StatementName1>
      <StatementName2>
    <dbTableName action=”INSERT”>
    <table>realDbTableName</table>
    <access>
    <col1>val1</col1>
    <col2>val2</col2>
    </access>
    <access>
    <col1>val11</col1>
    </access>
    </dbTableName> 
      </StatementName2>
      <StatementName3>
    <dbTableName action=”DELETE”>
    <key1>
    <col2>val2old</col2>
    <col4>val4</col4>     
    </key1>
    <key2>
    <col2>val2old2</col2>
    </key2>
    </dbTableName> 
      </StatementName3>
      <StatementName4>
    <dbTableName action=”SELECT”>
              <table>realDbTableName</table>
    <access>
    <col1/>
    <col2/>
    <col3/>     
    </access>
    <key1>
    <col2>val2old</col2>
    <col4>val4</col4>
    </key1>
    <key2>
    <col2>val2old2</col2>
    </key2>
    </dbTableName> 
      </StatementName4>
      <StatementName5>
    <storedProcedureName action=” EXECUTE”>
              <table>realStoredProcedureeName</table>
    <param1 [isInput=”true”] [isOutput=true] type=SQLDatatype>val1</param1>
    </storedProcedureName > 
      </StatementName5>
      <StatementName6>
    <anyName action=” SQL_QUERY” | “SQL_DML”>
    <access>SQL-String with optional placeholder(s)</access>
    <key>
      <placeholder1>value1</placeholder1>
      <placeholder2>value2<placeholder2>          
    </key>
    </anyName > 
      </StatementName6>
    </root>
    Mudit

  • Went with Verizon because the rep and Verizon's coverage map showed strong 4G LTE signal at my address. Got home and discovered that the signal is nowhere near what I was shown. People have said that they contacted Verizon and received signal boosters and

    Went with Verizon because the rep and Verizon's coverage map showed strong 4G LTE signal at my address. Got home and discovered that the signal is nowhere near what I was shown. People have said that they contacted Verizon and received signal boosters and I was wondering if anyone had knowledge of this?

        jslack73,
    Thank you so much for those details. I do see that the area should have pretty good coverage. Since you have been at home have you been able to remove the sim card for a good 10-15 seconds http://vz.to/1ys6Uj0? Also, please try resetting the network settings on the phone. You can do that by going into Settings, General, Reset, and Reset Network Settings. After this is complete you would need to re-add in your wi-fi passwords. Please keep us posted.
    KevinR_VZW
    Follow us on Twitter @VZWSupport

  • Table name in Receiver JDBC Adapter

    Hi All,
    I am using receiver JDBC adapter.
    But table name consist of " like BPC."#II" .
    After mapping table name becomes BPC.&quot;#II&quot; .
    I am getting error while pulling data from DB.
    Is the table name creating a problem.
    Please remedy of this if you have come across such scenario.
    Regards
    Piyush

    Hi Piyush,
    All that i could get from the SAP Help regarding JDBC Adapters are these links where i never found anything much regarding the table name.anyways just go through these links and see if you find anything useful.
    http://help.sap.com/bp_bpmv130/Documentation/Planning/XIUnicodeGuide030411.pdf
    <a href="http://help.sap.com/saphelp_nw04/helpdata/en/b0/676b3c255b1475e10000000a114084/content.htm">Configuring the Receiver JDBC Adapter</a>
    <a href="http://help.sap.com/saphelp_nw04/helpdata/en/cf/406642ea59c753e10000000a1550b0/content.htm">Mapping Lookups</a>
    <a href="http://help.sap.com/saphelp_nw04/helpdata/en/22/b4d13b633f7748b4d34f3191529946/content.htm">JDBC Adapter</a>
    <a href="http://help.sap.com/saphelp_nw04/helpdata/en/64/ce4e886334ec4ea7c2712e11cc567c/content.htm">Configuring the Receiver JDBC Adapter - part 2</a>
    This is all i got from the help files, anyways you can also go through those links and see if you find anything else useful.
    - Escape Symbol for Apostrophe
    The apostrophe character (‘) is a reserved character in SQL syntax and is therefore replaced by an escape character if it occurs within value strings. This replacement character can be database-specific. Typical replacement characters are \’ or ’’(default value). If a character occurs that is invalid for the database being used, the adapter triggers an error message (an SQL exception) concerning the SQL syntax that is generated by the database.
    - Column Name Delimiter
    Depending on the database being used, column names can be enclosed by a special delimiter character, for example, if the names can contain special characters (such as ”). This character can be specified at this point. The default setting is no delimiter character. If a character occurs that i
    Also check if there are notes in the service market place related to the same.
    Regards,
    abhy
    Message was edited by: Abhy Thomas

  • Data Type, Message Type and Mapping for FTP

    Thanks in advance for your replies.
    As our first production XI scenario, we need to move several (at least 46) files from our SAP instance to a couple of different servers to support our legacy systems.  Once all locations are on SAP this requirement should go away.
    I only want to pick up the file from the one server and place it on the other and this leads me to some questions.
    How do I define the Data Type and Message Type for each of the files?   Do I need to consider the size of the record in each interface and create DT/MT with different sizes.
    Do I need a mapping program that simply maps one structure to the other?

    I recently completed a similar exercise.
    It looks like this...
    server1 ftp (Sender - delete file) - XI - Server2 ftp (receiver - create file).  This will move the file from one server to another.
    I used the same schema and mapped fields on a one to one basis.
    The Size of the files I process are between 6kb and 500kb each, but the mapping/fields remain constant, just the numebr of items change.
    Worked seemelessly for the last three weeks (since go-live)

Maybe you are looking for

  • Text paramter with data type sting, not working

    Hi Guys, Im using BIP Standalone 10.1.3.4, and have come across a unusual problem.. probably a bug. Ive created a report with a parameter. The parameter type is text, and datatype String. (this problem only seems to occur if the string value is a com

  • Bug 10.5.9

    Hi, After Update Director 11.5.9. AS2 and AS3(Classic Text box ) cursor was Disappear.I use More Flash Text box in my project. Any Solution.

  • Oracle 9iAS 9.0.2.1

    I have installed the software for Oracle 9iAS 9.0.2.1, i need to configure the same. I am searching for : 1. any guide that will help me do the same (Oracle 9iAS Administration Guide) and 2. Any Configuration Assistant tool. So that i can deploy my a

  • VA11 - Additional Tab in the screen

    Hi All, I want to have an additional 'Tab' in the screen for VA11. Is there any screen exit available for this ? I wasn't able to find any and would like you guys to help me in letting know if there is any available. Also if not a screen exit, is the

  • How to reinstall Photoshop Elements without losing the catalog?

    Hello all, I find myself in an awkward situation. For a reason unknown, it seems an essential file for Photoshop Organizer has been deleted. I suspect a disk cleanup utility to have been a bit overzealous. Anyway the harm is done. When I try to start