Skip to Content
author's profile photo Former Member
Former Member

Doubt in mapping

Dear All,

I have a doubt . My source File structure is :

<Record>

+<country code>ULK</country code>

+<company code>01</company code>

+<Desc>ddd</desc>

</Record>

<Record>

+<country code>ULP</country code>

+<company code>02</company code>

+<Desc>eee</desc>

</Record>

<Record>

+<country code>ULK</country code>

+<company code>01</company code>

+<Desc>fff</desc>

</Record>

now depending on the combination of country and company code i need to decide the receiver

so Receiver A should get the following file :

<Record>

+<country code>ULK</country code>

+<company code>01</company code>

+<Desc>ddd</desc>

</Record>

<Record>

+<country code>ULK</country code>

+<company code>01</company code>

+<Desc>fff</desc>

</Record>

Receiver B should get the following file :

<Record>

+<country code>ULP</country code>

+<company code>02</company code>

+<Desc>eee</desc>

</Record>

Your solution on this will be appreciated and points will be awarded.

I tried to use conditional receiver determination using the company code & country code but it is delivering all 3 records to both target. Is it possible in conditional receiver determination to filter the rows automatically based on filter criteria?

REGARDS,

Add a comment
10|10000 characters needed characters exceeded

Related questions

2 Answers

  • Posted on Jan 29, 2008 at 06:52 PM

    Sunil,

    Please see the following which I quoted in the other thread.

    In the search criteria

    Date range : Last Year

    Search Terms : Linsy Scaria

    You will get the below thread name in the top of the list

    Re: Condition In Receiver Determination Not Working - Open that thread go to the 3 page and see the solution.

    Hope it might solve ur scenario.

    raj.

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Jan 29, 2008 at 07:00 PM

    Hi Sunil,

    This was the Expert Raj Post for the Above mentioned Thread,

    -


    Did u solved the issue? I think u might have solved the issue, please share with us the same. Today I tried ur scenario with enhnaced receiver determination its working perfect.

    I'm sharing the same, If you have any doubts kindly reply back.

    Please keep the blog as reference: /people/venkataramanan.parameswaran/blog/2006/03/17/illustration-of-enhanced-receiver-determination--sp16

    As for as your scenario is concerned its like File -XI- JDBC, based on the Plant value from the source if its 1000 it has to go to one receiver , if its 1111 it has to go to other receiver am I right?.

    Design Part.

    Create one source data type, message type and aynch outbound interface.

    Create two target data type,message type and aynch outbound interface.Even though both the target structure are same , I request you to create with two different names , u will get the flow below

    Create three Message Mappings and 3 Interace mappings

    Mapping 1:

    Source --> Target 1

    The logic is map if the source values has Plant value =1000

    Please refer : http://www.flickr.com/photo_zoom.gne?id=572921073&size=o

    Mapping 2:

    Source --> Target 2

    The logic is map if the source values has Plant value =1111

    Please refer :http://www.flickr.com/photo_zoom.gne?id=572921095&size=o

    Mapping 3:

    Source --> Receiver DeterminationAvailable in SAP Basis

    Please refer : http://www.flickr.com/photo_zoom.gne?id=572921149&size=o

    Please refer: http://www.flickr.com/photo_zoom.gne?id=572921161&size=o

    UDF Decide Receiver

    Create Advanced UDF Queue, with one input parameter -Plant

    int cnt = Plant.length;

    int party1=0,party2=0;

    for(int i=0;i<cnt;i++)

    {

    if(Plant.equals("1000") && party1==0)

    {

    party=1;

    result.addValue("Party1000");

    }

    else if(Plant.equals("1111") && party2==0)

    {

    party=1;

    result.addValue("Party1111");

    }

    }

    Create three Interface mappings for the above 3 message mappings.

    Directory Part

    Create three services ,one for file sender , one for JDBC receiver1Party1000 , one for JDBC receiver2Party1111.

    Create sender agreement --> File sender

    Create receiver determination --->Choose extended and choose mapping program 3rd defined in IR.

    Please refer :http://www.flickr.com/photo_zoom.gne?id=572505270&size=o

    Create 2 Interface determination. Bcoz we have created 2 inbound interfaces and choose the corresponding mappings

    Create 2 Receiver agreements.

    Please refer here to check whether you have all the objects : http://www.flickr.com/photo_zoom.gne?id=572921171&size=o

    Thats it you are done!!!

    In SXMB_MONI u must get like refer here : http://www.flickr.com/photo_zoom.gne?id=572921167&size=o

    Please see the below sample source and target messages.

    http://sapient.xi.googlepages.com/home

    I hope it helps you!!!

    Best regards,

    raj.

    -


    Regards

    Agasthuri Doss

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.