cancel
Showing results for 
Search instead for 
Did you mean: 

Issue with Insert and Delete in JDBC Reciever

Former Member
0 Kudos

Hi,

I am working on a IDOC to JDBC Scenario,

i have a custom IDoc with 2 segments

segment1 1..1

Segment2 0....99999999

the second segment had 3 fields and one of then is a flag field with possible values D(Delete) and I(Insert). my mapping works fine but if the idoc has data with both I and D indicators then only statement 1 with Delete attribute gets created in the XML.

Please suggest how should i map the 2 statements for Delete and Insert.

Regards,

Tarun Bahal

Accepted Solutions (0)

Answers (4)

Answers (4)

Former Member
0 Kudos

Hi Tarun,

There is problem with Mapping statement2...plz check it again

Please read this carefully for how db statement will look like...all ur doubts will be solved.

http://help.sap.com/saphelp_nw70/helpdata/EN/22/b4d13b633f7748b4d34f3191529946/frameset.htm

Regards,

Manisha

former_member732072
Active Participant
0 Kudos

Hi Tarun,

Please have a look at the following links and see if it helps you

and

also

Best Regards

Edited by: Prakash Bhatia on May 2, 2009 5:28 AM

former_member200962
Active Contributor
0 Kudos
if the idoc has data with both I and D indicators then only statement 1 with Delete 
attribute gets created in the XML.

Does this behavior (first node value taken into consideration) happen if you have statement 1 with Insert?if Yes then there is problem with the Context of the corresponding source node used in the mapping....

You either need to raise the context of the source node to that of a suitable higher node or you need to use the RemoveContext function available in the mesage mapping.

Regards,

Abhishek.

Former Member
0 Kudos

Tarun,

Are you mapping segment 2 of your IDoc to statementName of your target SQL statement?

Raju Kurukuri