cancel
Showing results for 
Search instead for 
Did you mean: 

How to - JDBC Sender.

Former Member
0 Kudos

Hi people, I'm wondering if somebody can provide an input on:

How to avoid the JDBC sender to pick incomplete sets of records...

Les say that we are polling for purchase orders on a table, and the process that fills the interface table hasn't finished yet writting the records, and when the channel gets kick (polling interval) it reads the table and gets an uncomplete document that was at the table at that moment.

How do you avoid this to happen? Is the read_commited parameter helpful to commit only complete documents to the DB?

Thanks, I will appreciate all your comments.

GR

Accepted Solutions (1)

Accepted Solutions (1)

VijayKonam
Active Contributor
0 Kudos

Useally one use staging tables for this. You first put the records in one table them move them to the final table where XI polls from. Or you can use a 3 state flag. 0 not ready. 1 being updated and 2 ready to be polled. Use this flag value in the XI select statemen of the sender channel.

VJ

Former Member
0 Kudos

Thanks for the quick response... I appreciate it.

So, just as you mention, I was thinking on a status field that will get flagged after all the records are posted into the interface table... But I was still having my doubts regarding on "what if" XI polls at the exactly moment when this records are getting updated with the flag field?

I know that if you test this concept with 1 or 2 records it work flawless... but if we are talking about thousand hundreds or million records, the time that the RDMS takes to update this can be longer than a second or two, so maybe XI can still be reading incomplete recordsets.

Another idea was to create some kind of BPM and will be polling for a trigger file, once that the trigger file is received, it will kick the communication channel to start polling the database table... Have you ever done this with XI?

Thanks for the advise.

Gerardo

Edited by: Gerardo on Aug 25, 2008 2:07 PM

VijayKonam
Active Contributor
0 Kudos

In that case you will have records with 0 or 1. XI is not interested in them. If some records are in the process of becoming 2, it will not read them at that moment since current status is 1. Next time it will take them. So all the time XI will read only completed records which have status 2.

VJ

Answers (0)