on 02-18-2011 5:40 AM
Hello all,
I have one scenario (JDBC to PI to IDOC). I am writing the SELECT and UPDATE in sender channel itself.
My issue is, when mapping is failing due to some reason the database is still getting updated. How can i avoid this UPDATE.
Thanks for all your help in advance.
Thanks,
Siddhesh
Update statement works when sender CC start working , so you can control this update statement, you have to write logic in mapping when mapping fails then change the key field value in Data base table.
but you have to be very carefull here.
Regards,
Raj
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Siddhesh,
I can think of one more solution which is slightly complex. You can do something like this -
1) On sender side - In JDBC sender channel, keep only SELECT command, and remove the UPDATE command.
2) On receiver side - In addition to the exisitng receiver (where you are sending IDocs), add one more reciever which is the sending system itself. Use JDBC receiver channel and the standard XML structure in which you can specify only the UPDATE command involving fields that you want to update in database.
3) Mappings section - You will need to create one new message mapping and interface mapping accordingly. In this interface mapping, plug in two message mappings in sequence as -
a) JDBC to IDoc mapping (which you must have already used for the first receiver)
b) JDBC to JDBC mapping.
So if the first mapping fails, the second will not get executed. Hope this helps.
Regards,
-Shankar
Hi,
Commit operation to database happends immediately after the channel picks the data and send to integration engine...
it will not take care of the mapping status ...
you need to resend the data from the Integration engine either or change the database stauts (not recommended but an oprtion..)
if you want to have the commit only after the operation has been finished..option can be to change the interface to synchronous or get the response from the target system with an id..of a table and based on this update the table in database...
HTH
Rajesh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
95 | |
11 | |
11 | |
10 | |
9 | |
8 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.