on 02-06-2009 10:22 AM
Hi,
How can we insert data in multiple tables without using BPM in certain predefined sequence.
My requirement is:
I want to insert in table A, then B, then C. Without using BPM
I want to avoid any stored procedure for this activity
Kulwinder
Hi Kulwinder,
just create 3 statements in order a,b,c in your datatype for jdbc receiver strucutre, jdbc adapter will execute it in sequence.
Thanks,
Tuhin
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
In your case, as you have multiple tables and data for all the tables comes in a single message from source, then you can't directly make sure the order of insertion. This is because the transaction handling capabilities at each table are independent of each other.
I disagree to what others have suggested till now.
Regards,
Prateek
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
thanks prateek.
So we have following options to achieve this ;
1) put all data as single statement and insert it in staging table. Stored procedure should pick it up from there.
or
2) call stored procedure itself directly from XI
Actually we want to avoid SP, because we have alsmot 20-30 interfaces like this and its lot of work to write SP for each.
Any other suggestion.
Kulwinder
Hi,
take your source msg.......create one target data type have JDBC strructer for table A, then below it table B and then table C...create one msg type and one msg interface for it............map it and execute your scenario........then JDBC recever comm channel will insert the records sequentially............
Regards,
Rajeev Gupta
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
86 | |
10 | |
10 | |
9 | |
7 | |
7 | |
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.