cancel
Showing results for 
Search instead for 
Did you mean: 

Xpath condation

pankaj_yadav3
Participant
0 Kudos

Hello Expert

I am creating a interface FILE ---> IDOC(ORDERSP)...

Requirement : In file Structure there is filed : ID . Based on Id value we will create the IDoc two different vendor .

Ex : Suppose If Field Id = 10 than we will create IDOC for 1010 vendor and if Id = 20 than we will create idoc for 1020 vendor . .

Please help me how we i can use the xpath condition for this requirement .

Regards

P.Singh

Accepted Solutions (0)

Answers (7)

Answers (7)

markangelo_dihiansan
Active Contributor

Hi Pankaj,

Well in that case, just input the same interface in interface determination and provide the conditions. It will be split depending on the contents of the idoc.

Regards,

Mark

markangelo_dihiansan
Active Contributor

Hi,

Create the two business systems (vendor1 and vendor2) first. Then in the xpath condition editor, navigate to the xpath field, use = sign and then on the right part of the equation input 10 then click OK. Then input vendor1 as the receiver.

Do the same for vendor2 except the value should be 20.

Regards,

Mark

apu_das2
Active Contributor
0 Kudos

What do you mean by more than one control record. For one IDOC, there will be only one EDI_DC40.

Use if else in the mapping to set required data in the MM. I believe you need to send idoc in only one vendor at a time like eithe 200 or 300.

Thanks,

Apu

pankaj_yadav3
Participant
0 Kudos

HI Evgeniy

Can we pass more than one control record in message mapping ?

Regards

P.Singh

former_member190293
Active Contributor
0 Kudos

Hi Pankaj!

Each of your IDocs in target message has its own EDI_DC40 segment (IDoc control record), so you can use conditional logic in your message mapping to set required values for each of your IDocs.

Regards, Evgeniy.

former_member190293
Active Contributor
0 Kudos

Hi Pankaj!

Then you should enable using control record in your adapter and set required values of control record in your message mapping.

Regards, Evgeniy.

pankaj_yadav3
Participant
0 Kudos

HI Mark Dihiansan

No , this solution is not working , because business component is one so we have able only one communication channel . I am filling the control record via communication channel . So We need to two communication channel.

Regards
P .Singh

markangelo_dihiansan
Active Contributor
0 Kudos

Hi Pankaj,

Not sure why you said this is not working. If you input two interfaces in the same interface determination, it will split into two (depending on the conditions), no need to create another communication channel since you will use the same receiver agreement.

Regards,

Mark

pankaj_yadav3
Participant
0 Kudos

Hi Marik

Thanks for update .

We can not crate two different business system .I have one business system like ECQ300 , and this system has so many vendor .So as per my requirement we will crate two idoc tow different vendor .