cancel
Showing results for 
Search instead for 
Did you mean: 

MDM to JDBC two receivers

former_member210677
Participant
0 Kudos

HI Team,

We need to create a scenario with MDM to JDBC having two receivers one for insertion and another for updation.

Could anyone give me suggestion on how to proceed futher.

Thanks & Regards,

Ranganath.

Accepted Solutions (0)

Answers (5)

Answers (5)

markangelo_dihiansan
Active Contributor
0 Kudos

Hello,

We need to create a scenario with MDM to JDBC having two receivers one for insertion and another for updation.

It depends on your requirements:

1.) Do you need the response from the update/insert? If yes, your scenario would be synchronous and you would be unable to use multi-mapping or multiple receivers without resorting to BPM. If no, then you can go through the suggestions by the posts above.

2.) Are the receivers the same or different systems?

a.) Same system, sync mode - this would proceed as a normal sync scenario

b.) Same system, async mode - use multi-mapping as suggested by Santhosh/Raja

c.) Different systems, sync mode - You would need to maintain two scenarios here since multi-mapping or message split cannot be used. Otherwise, go for BPM

c.) Different systems, async mode - use receiver determination for the split and then standard interface determination as was suggested by Baskar/Grzegorz

3.) What is your update/insert logic? e.g if the data is existing you will just update and if it is not then it will insert? If that is the case, you can use the UPDATE_INSERT statement

http://help.sap.com/saphelp_nwpi711/helpdata/en/44/747eda12dd3676e10000000a114a6b/frameset.htm

Or if the statement is complex, use SQL_QUERY

Hope this helps,

Mark

former_member210677
Participant
0 Kudos

Hi Team,

Thanks a lot for your prompt replies..and am obliged to get your suggessions on the requirement

But Now I got a modification in the requirement

Its like we need to pull data from Oracle and post it to MDM and again to oralce to update it.

Design goes like one sender jdbc channel with two recievers one for MDM and one for same oracle table for updation and this is to avoid missing records.

So could you please suggest me how to proceed. is there any way to change the design or should i go ahead with this design..

Awaiting your replies..

Thanks & Regards,

Ranganath.

rajasekhar_reddy14
Active Contributor
0 Kudos

Hi,

JDBC sender channel we perform two actions once is seelct then update.

select statment pulls data from DB and Update statement updates flag status same time,so it avoids seelcting old data once again.

if you still want too perfrom update operation then use multi mapping concept without BPM.

let us know still you need clarity

Regards,

Raj

Former Member
0 Kudos

Hi Ranganath,

For your requirement,

>>> Its like we need to pull data from Oracle and post it to MDM and again to oralce to update it.

You can go for a straight forward approach. You may configure the Sender JDBC adapter to poll the Oracle db for data via the standard SELECT statement and then once the data is read, you may update the selected rows via a proper UPDATE statement. Both the SELECT & UPDATE can be configured in the same JDBC sender Adapter and the MDM receiver will be part of the normal flow.

Hope this helps.

Regards, Gaurav

former_member210677
Participant
0 Kudos

Hi Kumar\Raja,

The issue here is while the SQL statements Select and Update are getting triggered there are some missing records happening in between these transactions. So wanted to have a new channel or any new technic for updating the records other than using the same update statement in sender channel.

So could you please suggest me how to proceed with multimapping here as for mdm we use matmas external def(as one of the receiver) and i need to use other structure to update the table in mapping.

Appreciate your help.

Thanks & Regards,

Ranganath.

rajasekhar_reddy14
Active Contributor
0 Kudos

Hi,

Please investigate why update statement not working perfectly,may be you need to alter it because updaet statement works perfectly.

if you want to use multi mapping concept refer below blog.

/people/jin.shin/blog/2006/02/07/multi-mapping-without-bpm--yes-it146s-possible

Regards,

Raj

former_member210677
Participant
0 Kudos

HI Raj,

here we are not accessing the direct table from oracle there is another table in which the records of the original table are refined as per the req and then sent to this new table. And now XI is accessing this new table. So in this process while XI is executing the select query say if there are 10 records to be fetched. in the meanwhile before the update statement gets executed there are some other records getting into the table and these are not fetched by XI where as, these are updated.

Which means there are some records getting into the table in between the select and update query executions.

and they are getting updated without getting fetched, which are resulting as missing records.

so inorder to avoid this we are trying to disable the update statement in sender channel and trying to look for an alternative.

could you suggest me any alternative in this regard,

Thanks & Regards,

Ranganath.

rajasekhar_reddy14
Active Contributor
0 Kudos

Update statement is mandatory in Sender channel and time gap between select statement and update statement almost zero,so writing update statement in sender channel is right approach.

I worked on sender JDBC scenarios we never had any prob like this.

Even if you implement update procedure at receiver side then def it will not give accuracy .

baskar_gopalakrishnan2
Active Contributor
0 Kudos

JDBC sender channel does first Query statement followed by Update Statement. Since a single thread executes the transaction you will not have issues. Doing select and update at the sender side is elegant and perfect design. You might want to check transaction isolation level to set in the jdbc sap help document.

rajasekhar_reddy14
Active Contributor
0 Kudos

Hi Ranganath,

if you are dealing with two different Data base systems then implement multi mapping concept(search in sdn multi mapping without BPM) or Santhos suggestion is best one.

Regards,

Raj

former_member184681
Active Contributor
0 Kudos

Hi Ranganath,

As far as I understood, you need to deliver the data to two separate systems, is that right? If so, then create a Receiver Determination with two receivers. The message from your MDM system will be automatically duplicated by the XI system, and both messages (after the split) will be processed independently in parallel. All you need is to prepare separate Message Mappings and Receiver Communication Channels for both of your receiver systems. Thanks to that, the data will be delivered to both systems just the way you want them to do it.

Hope this helps,

Grzegorz

baskar_gopalakrishnan2
Active Contributor
0 Kudos

>Could anyone give me suggestion on how to proceed futher.

If you have two different database, then you have to create two different receiver system and respective comm channels. If you are dealing with updates and insert with the same database, then construct the single receiver structure message with two statements node one with update and another with insert. Please refer SAP Help document for the JDBC message structure.

Former Member
0 Kudos

Hi,

2 receivers not needed.

Create one MT with 2 structures, one for Insertion & one for Updation.

Am not sure, if you want to Insert/update parallelly or sequentially.

Either way, it can be handled in mapping by putting conditions.

if one at a time, put a condition that, if INSERT, go for struc1, else UPDATE go for struc2.

<StatementName1>

--<dbTableName action=u201DINSERTu201D>

-<table>--


assingn to table1

---<access>

-


<col1>val1</col1>

-


<col2>val2</col2>

---</access>

</StatementName1>

<StatementName2>

--<dbTableName action=u201DUPDATEu201D>

-<table>--


assign to table2

---<access>

-


<col1>val1</col1>

-


<col2>val2</col2>

---</access>

</StatementName1>

so, it will be

1 send CC, SA, RD,IA,Rec CC, RA.

-santosh.