cancel
Showing results for 
Search instead for 
Did you mean: 

JDBC adapter table update Behaviour in PI

Former Member
0 Kudos

Hello Experts ,

I have Proxy to JDBC scenario ,please let know is there possible way to insert more than one line diff item for the same record ??

Could you please explain the behavior of JDBC adapter.

For Instance :

Expected Behavior:

Po number1 , item1 . ( first level of execution )

Po number1 ,  item2. (second level of execution )

Actual Behavior :

Po number1 ,  item2. (second level of execution )

In my scenario it is updating only the recent value , could you please suggest me .

Regards

Raja

Accepted Solutions (0)

Answers (3)

Answers (3)

baskar_ramasamy
Participant
0 Kudos

Hope this helps....

Former Member
0 Kudos

Hi Rajavadivel,

>>>please let know is there possible way to insert more than one line diff item for the same record ??

If you remove PoNumber field under KEY element then it inserts more than one line diff item for the same record/diff record. Make sure that action must be UPDATE_INSERT.


What ever the field you define under Key Element that field consider it as PrimaryKey. So for new PoNumber it insert the new record and if its a same PoNumber then it update the existing record with latest item value.

Former Member
0 Kudos

Hi ,

Hope you are doing as below in mapping.

Open insert statement twice and don't use PO Number as key field value .

Ex:

case1:

Insert into tablename(ponumber,item)  values(123,'xyz') ;

Insert into tablename(ponumber,item)  values(123,'rtz') ;

O/P:two records gets inserted

123  xyz

123 rtz

case2:

Insert into tablename(ponumber,item)  values(123,'xyz') where ponumber =123 ;

Insert into tablename(ponumber,item)  values(123,'rtz') where ponumber =123 ;

O/P:2nd record overwrites the 1st record

123 rtz

Regards

Venkat

Former Member
0 Kudos

Hi Venkat,

As u suggest , I have used combination of both PO no and PO item as a KEY field thus am getting the same issue, its overwrites the same entry rather of creating new entry. could you please suggest me the feasible solution .


what is the behavior of updating the table ??

Thanks

RAJA