cancel
Showing results for 
Search instead for 
Did you mean: 

Sender File adapter

naveen_chichili
Active Contributor
0 Kudos

Hi All,

I am trying to send a csv file ti DB where i have set a primary key for one field in my JDBC table which has to be unique.

I handled ID generation sequence in mapping using global variables to get a unique number into DB table....If there are multiple files in the sender location, sender adapter is picking all the files at a time and processing the files at a time....and getting error in reciever communication channel as all the files are generating the same value while inserting into the DB table.

Could you please let me know how i can pick each file from the sender location instead of multiple files processing at a time...

Thanks in advance,

Naveen.

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi,

You can use the parameter connect mode as per file transfer instead of permanent. By using this Per File Transfer mode the adapter will make the connection establish for every file transfer. In this case your issue will be resolved. So let me know your update after implementing this,

Regards,

Raju

naveen_chichili
Active Contributor
0 Kudos

Hi All,

Any other suggestions please...

Regards,

Naveen

Edited by: chichilin on May 25, 2011 7:21 PM

Former Member
0 Kudos

Hi,

U can go with stored procedure option in this case.

U can request stored procedure from DB people and give them ur requirement. They can write set of code which can generate unique ID. And u can call that stored procedure from Reciever JDBC channel.

Regrads,

Bhuvan.

Former Member
0 Kudos

Hi,

Instead of generating the unique id ...get the message id generated by the PI system and use the same while inserting into the database...

PI message id will be unique even if multiple files are picked..

if that is not unique..then another possibility is use of timestamp which will be unique...

HTH

Rajesh

naveen_chichili
Active Contributor
0 Kudos

HI Rajesh,

Thanks for quick reply...

My requirement was to idetify the order number in table which i have generated a sequence to be unique in DB.

Do we have any option to process a single file at a time from the sender location instead of multiple files...i can see processing sequence <bydate> option in nfs but not in FTP.

Please suggest....

Thanks in advance,

naveen

Former Member
0 Kudos

Hi,

Maybe you can try EOIO instead of EO and in the runtime workbench, give the no of processing nodes for your adapter as 1.

Regards