FILE-BPM-MULTIPLE BAPIS

HI EXPERTS,
I AM FRESHER IN BPM.
HERE IS A SCENARIO I HAVE TO IMPLEMENT.
    A TEXT FILE(SALES) WAS RECEIVED AND IT SHOULD BE SEND TO XI(BPM) WHICH WILL BE CONNECTED TO 4 BAPI'S . HERE THE SCENARIO IS,  BASED ON THE FIRST BAPI RESPONSE , SECOND BAPI REQUEST WILL BE GENERATED.
BASED ON SECOND BAPI RESPONSE, THIRD BAPI REQUEST IS GENERATED. AND FOURTH BAPI IS GENERATED BASED ON THIRD BAPI RESPONSE.
I THINK I GAVE SUFFICIENT INFORMATION.
POINTS REWARDED..........
THANKS IN ADVANCE.

Hello,
Check this thread,
FILE to multiple BAPI/RFC calls
**********Reward points,if found useful

Similar Messages

  • FILE to multiple BAPI/RFC calls

    Hi,
    I have one input source (CSV with about 100 rows) and I wish to call a custom rfc for each row in my spreadsheet. (The custom RFC has a single flat import structure as opposed to a table or anything complex).
    I am struggling to do this in XI.
    I assumed I needed to assign one source to multiple targets in the Message interfaces, but this errors on activation due to the RFC occurrence being set to 1.
    Do I need to do the same trick as with IDOCS or am I missing the point somewhere?
    I have read several threads and one in particular seems to indicate it is possible, but so far this has evaded me.
    Re: BOM CREATION
    Please could you point me in the right direction.
    Thanks
    Andrew

    Andrew,
    You could read the CSV file into an Integration Process
    Save the message in a multiline container (in your case 100 rows)
    Create a block
    Create another container to hold the single row defined within this block
    Set the following for the block
    <b>Step Name</b>          eg SplitForRFC
    <b>Mode</b>               ParForEach
    <b>Multiline Element</b>     Multiline container defined above
    <b>Current Line</b>          Single line container defined above
    The <b>Mode</b> 'ParForEach' acts like a loop
    Then within the block create a synchronous Send step which calls your RFC
    <b>Design</b>
    I would question having to make 100 RFC calls
    If possible change the design so that the RFC interface can accept multiple messages and the RFC logic to loop through them and process the messages one at a time
    Regards,
    Mike

  • BPM multiple files issue

    Hi,
    I am using BPM to pick the two files and merge to one it sent to Receiver. If My source folder is having two files bpm successfully processing the file for example I am having file names like this
            SAP_08-01-2011_1.TXT AND SAP_08-01-2011_2.TXT
    The files are coming to XI through schedular automarically. Some times the 2 set of files are coming to XI at a time like this
    SAP_08-01-2011_1.TXT AND SAP_08-01-2011_2.TXT  and  SAP_09-01-2011_1.TXT AND SAP_09-01-2011_2.TXT
    In this situation XI some times it is picking the other date file and try to process in BPM in result wrong data is going to receiver.
    Like
    SAP_08-01-2011_1.TXT AND SAP_09-01-2011_2.TXT    are processing
    *ACTUVALLY  SAP08-01-2011_1.TXT AND SAP_08-01-2011_2.TXT  FILES NEED TO PROCESS*_
    How to avoid this processing in BPM means same set of files need to be executed in BPM .
    I am using BPM below steps to achive this
    1. FORK STEP
    2. TWO RECEIVE STEPS
    3. TRANSFORMATION STEP
    4. SEND STEP.
    To process the same set of files
    SAP_08-01-2011_1.TXT AND SAP_08-01-2011_2.TXT  need to process in BPM
    SAP_09-01-2011_1.TXT AND SAP_09-01-2011_2.TXT  need to process in BPM
    If we want to send the same set of files to BPM wht need to do .
    Regards,
    Eswar

    Hi,
    You have to define the correlation on the date.
    When the date part in the filename is same; those two files will be picked up & processed.
    -Supriya.

  • File - BPM - BAPI_COMPANY_GETDETAILS File

    Hi,
    I'm in a little trouble...
    I had a working scenario with File -> BPM -> BAPI_COMPANY_GETDETAILS -> File as found in a Blog.
    The first file contains one company code and the RFC sync call gets the details and then sends the info back in a file.
    To get closer to my final scenario, I enhenced this scenario qith having in the first file, multiple instance of the CompanyID (I created a special DataType, Message Type, .. for that) then in my BPM, I started with the receive step, then a transform 1 to N and then a bloc foreach that included the Sync RFC call and the send call as before.
    My trouble is that now the RFC call sends me back an error (with same companyID then before)
    Type - Code - Message
    E - FN030 - Company 1 does not exist
    but if I do the BAPI call with SE37, I get the correct results...
    Has any one an idea ? It keeps me mad from this morning !
    Thx in advance!!
    Cheers
    greg

    Here is the message as it comes back from the RFC call:
      <?xml version="1.0" encoding="UTF-8" ?>
    - <rfc:BAPI_COMPANY_GETDETAIL.Response xmlns:rfc="urn:sap-com:document:sap:rfc:functions">
    - <COMPANY_DETAIL>
      <COMPANY />
      <NAME1 />
      <NAME2 />
      <COUNTRY />
      <LANGU />
      <STREET />
      <PO_BOX />
      <POSTL_COD1 />
      <CITY />
      <CURRENCY />
      <COUNTRY_ISO />
      <CURRENCY_ISO />
      <LANGU_ISO />
      </COMPANY_DETAIL>
    - <RETURN>
      <TYPE>E</TYPE>
      <CODE>FN030</CODE>
      <MESSAGE>Company 0001 does not exist</MESSAGE>
      <LOG_NO />
      <LOG_MSG_NO>000000</LOG_MSG_NO>
      <MESSAGE_V1>0001</MESSAGE_V1>
      <MESSAGE_V2 />
      <MESSAGE_V3 />
      <MESSAGE_V4 />
      </RETURN>
      </rfc:BAPI_COMPANY_GETDETAIL.Response>

  • Multiple BAPI calls in RFC Adapter

    Hi, Dear Friends!
    I have asynchronous scenario File to RFC(BAPI).
    File contains raws. For each raw I need to execute BAPI.
    With the help of each raw I need to construct one document in R/3 database with the help of BAPI.
    But now my scenario provide only one document (only one BAPI is executed).
    I read file to xml structure. This structure contains elements. The elements represent raws of file. But BAPI is executed only for the first element.
    How to explain to XI that I want it impement BAPI <b>N times</b> - as number of raws in file (or elements in xml structure).
    So how to implement multiple BAPI calls. Have you any idea?
    Thank you in advance.
    Natalia Maslova.

    Hi Natalia
    have a look on these links
    http://help.sap.com/saphelp_nw04/helpdata/en/43/b46c4253c111d395fa00a0c94260a5/frameset.htm
    Best Design : for a SOAP -XI - BAPI ( Multiple )
    Re: RFC adapter...How it handles multiple calls...
    Re: Multiple BAPIs and COMMIT in BPM
    Re: Is it possible to compose XML in BPM from responses of multiple BAPI calls?
    Multiple BAPI calls in RFC Adapter
    may be helpful
    Thanks !!!

  • Error Handling in File to Multiple IDOC Scenario?

    Hello Experts,
    My scenario is file with Multiple records and I want to send it to SAP system.If there will be 10 Records in my file I need to create 10 IDOC in Target system.
    I can use below of the two options.
    1) File to Multiple Idoc (1.N Mapping)
    2) Using BPM
    3)Directly place the file in SAP application server and process it via ABAP Program.
    However I am not clear in which option error handling will be more effective.Please suggest.
    Basically I want to handle If out of 10 records 9 are correct and 1 record is not correct then I should be able to report within PI without affecting 9 correct records.Is it possible 9 records will be sent to SAP system and PI will only show error for 1 incorrect record.
    Also I will be doing this scenrio for transaction data with huge size (1 Million Records).Which approach will be more effective in this case.
    Thanks,
    Pushkar

    Hi Patel,
    I want to handle If out of 10 records 9 are correct and 1 record is not correct then I should be able to report within PI without affecting 9 correct records.Is it possible 9 records will be sent to SAP system and PI will only show error for 1 incorrect record.
    when working on graphical mapping, the target structure is created when there are no errors in all records of source structure.
    suppose if we have validation error in 9th and 10th record, then we can not process the first eight records and inturn we can not store the two error records in XI for further.
    i suggest you the third option, you can directly place the file in SAP application server and process it via ABAP Program.
    this is far better because you can do more customizations as you have to deal with millions of records.
    Regards,
    Pradeep A.

  • File to multiple idoc

    Scenario is Fileu2013TOu2013Idoc. We have a requirement where we need to produce multiple idocs from one file.
    The input file is something similar to this:
    HEADER;XYZ;123;123456
    DETAIL;XYZ;123;123456
    DETAIL;XYZ;123;123456
    DETAIL;XYZ;123;123456
    DETAIL;XYZ;123;123456
    TRAILER;XYZ;123;456
    Now for every 1000 "DETAIL" records from the above structure it should create MULTIPLE IDOC's in SAP.
    In PI, Integration directory, under "File Content Conversion" added 2 lines as below:
    Recordset Structure=DETAIL,1
    Recordset per Message=1000
    This splits the FILE to many messages (each 1000 DETAIL) in PI (SXMB_MONI) and creates many IDOC (only if FILE has DETAIL records).
    However this works only if the FILE has all DETAIL records (no HEADER, no TRAILER).
    Can someone suggest how to use "Recordset per Message" if there are more NODEs in the input FILE?
    Thank you very much.

    Suraj
    Thanks.
    I got your point. I also read Enhanced (Mapping-Based) Interface Determination http://help.sap.com/saphelp_nw04/helpdata/en/42/ed364cf8593eebe10000000a1553f7/content.htm.
    It appears target IDOC message splits are not supported since the IDOC adapter is not part of the AE. /people/jin.shin/blog/2006/02/07/multi-mapping-without-bpm--yes-it146s-possible
    So I will use your approach in two steps. Please let me know if my understanding is correct.
    Step 1:
    FILE to FILE
    1. Read the source file and do a FCC.
    2. Write splitting logic (per 1000) in udf
    3. Use multimapping and enhanced interface determination
    4. Write source file to multiple target files. FILE1,2..N
    Step 2:
    FILE1,2,3..N to IDOC
    1. Normal mapping. (Note: no change of IDOC occurrence of idoc to 1 ot unbounded is needed as original message is split to multiple files in step 1)
    Appreciate the input.

  • File-XI-multiple IDoc Scenario

    Hi there -
       I am working on single File-XI-multiple IDoc Scenario and have following questions:
    (please keep in mind that there is already an existing multiple IDocs-XI-single File scenario between the same systems)
    1. Please provide any detailed step by step documentation from end-to-end.
    2. I am thinking it's compulsory to use BPM, is there any way to aviod?
    3. Is it possible to update existing IDocs in R/3 directly from the data from XI?
    Thanks everyone in advance...
    Pat

    HI,
    Pls go thru following links-
    /people/michal.krawczyk2/blog/2005/12/04/xi-idoc-bundling--the-trick-with-the-occurance-change
    Single inbound file -> XI -> Multiple IDOCs in SAP
    One file for multiple IDOCs
    Hope this helps..
    Regards,
    Moorthy

  • If CSV file contains multiple structure...

    If CSV file contains multiple structures...then how should set vaules in file content conversion.
    pls mention any links regarding File Content Conversion
    thanks in advance..
    Ramesh

    Hi,
    You are using RecordSet. Here are some scenarios.
    http://help.sap.com/saphelp_nw04/helpdata/en/2c/181077dd7d6b4ea6a8029b20bf7e55/frameset.htm
    /people/venkat.donela/blog/2005/03/03/introduction-to-simple-file-xi-filescenario-and-complete-walk-through-for-starterspart2
    /people/prateek.shah/blog/2005/06/08/introduction-to-idoc-xi-file-scenario-and-complete-walk-through-for-starters - IDoc to File
    /people/ravikumar.allampallam/blog/2005/03/14/abap-proxies-in-xiclient-proxy - ABAP Proxy to File
    /people/sap.user72/blog/2005/06/01/file-to-jdbc-adapter-using-sap-xi-30 - File to JDBC
    /people/prateek.shah/blog/2005/06/14/file-to-r3-via-abap-proxy - File to ABAP Proxy
    /people/venkat.donela/blog/2005/03/02/introduction-to-simplefile-xi-filescenario-and-complete-walk-through-for-starterspart1 - File to File Part 1
    /people/arpit.seth/blog/2005/06/27/rfc-scenario-using-bpm--starter-kit - File to RFC
    https://www.sdn.sap.com/irj/sdn/weblogs?blog=/pub/wlg/1685 [original link is broken] [original link is broken] [original link is broken] [original link is broken] - File to Mail
    Regards,
    Wojciech

  • Single inbound file - XI - Multiple IDOCs in SAP

    Hi XI pros,
    my file input file has very simple structure of header and item:
    H
    L
    L
    L
    Header has 2 fields snd item has 3 fields which I need to map to IDOC and post simple MM document in SAP.
    Mapping itself is very easy. I need to create separate IDOC for every item record type L.
    Question is whether I can do this in general without BPM ?
    Thank you, Forest.

    Hi Forest,
    Go thru this blog of <b>File to Multiple IDoc's</b>
    /people/anish.abraham2/blog/2005/12/22/file-to-multiple-idocs-xslt-mapping
    I think this satisfy ur requirements.
    Hope it helps and u don't forget to give me points.
    Regards
    Arpit Seth

  • Configuration scenario of file to multiple IDOCs in XI

    I have to configure a scenario of file to multiple IDOCs in XI.
          I have XML file in MDM server. And it contains multiple segments. Each Segment is  a combination of DEBMAS and ADRMAS.
    So in XI configuration I have to separate the mapping for DEBMAS and ADRMAS. And my ADRMAS idoc should post first in R3 and then DEBMAS should post.
    These IDOCs are multiple because each segment in XML file will be a IDOC.
    Does BPM process is mandatory here or we can do in any other way.
        Could you please suggest how to do this configuration. If you have any documents pls share with me.
    Regards,
    Venkat

    Hi,
    First you need to split the messages into multiple IDOC types. As you are going to send this to IDOC adapter, it is required to have BPM to split the message.
    These 2 docs may help u:
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/cdded790-0201-0010-6db8-beb9bb2b2660
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/877c0d53-0801-0010-3bb0-e38d5ecd352c
    Regards,
    Moorthy

  • Single File to multiple IDoc

    I am working on single XML file input to multiple IDoc scenario. Single file contains multiple set of data for Customer and Vendor for example 20 Customer and 40 vendor together in one file between <CMData>...</CMdata> tag individually. I have to map Customer and Vendor based on one of the tag value. I seen the IDoc structure does not allow multiple records and occurrence shows only one. What is the best way to establish this scenario. I know ccBPM is required and Transformation Step picks respective mapping based on XML tag value for Customer or Vendor, but I have doubt how can I send one by one IDoc by identifying correct mapping based on XML tag. Thanks and appreciate your help.
    --PKT

    Thanks Paul for prompt response and support.
    I changed the Occurrence of both IDOC TAG to "9999" through "xsd" and upload the same in XI and I created two mapping one for Customer and one for Vendor i.e.
    File--->Customer with multiple IDoc tag attribute
    File--->Vendor with multiple IDoc tag attribute
    Now in BPM I have to apply loop and look to the tag XMLType and where it is "C" I have to call Customer mapping and where it is "V" I have to call Vendor mapping. How I can do this . Please help me on this. Thanks.

  • File to multiple IDOC(message)

    Hi
    I need to map file to multiple IDoc type  that means on source message have two target message . Any ideas how to achieve that
    Thanks in advance
    Regards
    Swatantra

    refer these weblogs that will give you an idea;
    Multi Mapping -
    BPM involved:
    /people/sudharshan.aravamudan/blog/2005/12/01/illustration-of-multi-mapping-and-message-split-using-bpm-in-sap-exchange-infrastructure
    /people/narendra.jain/blog/2005/12/30/various-multi-mappings-and-optimizing-their-implementation-in-integration-processes-bpm-in-xi
    Without BPM:
    /people/jin.shin/blog/2006/02/07/multi-mapping-without-bpm--yes-it146s-possible

  • Correlation for files containing multiple records

    I was learning correlation from a nice blog below.
    /people/milan.thaker/blog/2008/07/23/correlation-150-runtime-behavior-of-bpm
    I have one question though. In the case where the correlation is done on  a key field say PsNo.
    Now if two files have multiple records, will the correlation compare the PsNo of each record or is the comparison just on the first PsNo of each file record.
    Thanks,
    Minhaj.

    Hi Minhaj,
    1) Suppose if you want to merge 2 files into a single file based on a keyfield (PsNo), You are opting Correlation in BPM.
    In your Correlation Editor, You should mention the XPATH Expression for Keyfield(PsNO) for the involved messages.
    2) Only if both the values of keyfied(PsNo) in 2 files are equal then Only you can merge all those 2 files into single file.
    So first PsNo of each file record is going to compared with another file.

  • How to Run Multiple BAPI's

    Hi All,
    i was trying to run multiple BAPI's using Jco. but no luck. it giving error message like "Employee/person not locked yet".
    the BAPI's i'm trying are
    1. BAPI_EMPLOYEET_ENQUEUE
    2. BAPI_ABSENCE_REQUEST
    3. BAPI_TRANSACTION_COMMIT
    4. BAPI_EMPLOYEET_DEQUEUE
    i'm using connection pooling to get connection.
    the code
    JCoDestination destination = JCoDestinationManager.getDestination(ABAP_AS_POOLED);
    JCoFunction function = destination.getRepository().getFunction("BAPI_EMPLOYEET_ENQUEUE");
    function.getImportParameterList().setValue("NUMBER", "00000002");
    function.execute(destination);
    function = destination.getRepository().getFunction("BAPI_ABSENCE_REQUEST");
    function.getImportParameterList().setValue("EMPLOYEENUMBER", "00000002");
    function.getImportParameterList().setValue("VALIDITYBEGIN", c.getTime());
    function.getImportParameterList().setValue("VALIDITYEND", c1.getTime());
    function.getImportParameterList().setValue("ABSENCETYPE", "0014");
    function = destination.getRepository().getFunction("BAPI_TRANSACTION_COMMIT");
    function.execute(destination);
    function = destination.getRepository().getFunction("BAPI_EMPLOYEET_DEQUEUE");
    function.getImportParameterList().setValue("NUMBER", "00000002");
    function.execute(destination);
    i don't know where i'm going wrong. Plx help me out.
    thanks in Advance.
    Ravi.

    Hi.
    I found the correct form to use.
    BAPI_EMPLOYEE_ENQUEUE
    BAPI_PERSDATA_CHANGE
    BAPI_EMPLOYEE_DEQUEUE
    In a java file need use JCoContext to generate a group functions to will be execute
    try {
    JCoContext.begin(destination);
         if (JCoContext.isStateful(destination))
              bloqFunction.execute(destination);
              cambFunction.execute(destination);
              desbFunction.execute(destination);
    } finally {
    JCoContext.end(destination);
    Declarated:
    JCoFunction bloqFunction = destination.getRepository().getFunction(
                        "BAPI_EMPLOYEE_ENQUEUE");
    JCoFunction cambFunction = destination.getRepository().getFunction(
                                            "BAPI_PERSDATA_CHANGE");
    JCoFunction desbFunction = destination.getRepository().getFunction(
                                            "BAPI_EMPLOYEE_DEQUEUE");
    I hope help with this.

Maybe you are looking for

  • What is the "Main Attribute" for in Session Monitoring?

    Anybody know what the "Main Attribute" column is for in session monitoring or how I can use it? Can't find it mentioned anywhere.

  • Is solidworks compatible with my macbook pro 7 intelcore duo using a bootcamp??

    I have a macbook pro 7 intelcore duo and i would like to install and use solidworks on it for my university work. So far i know im required to bootcamp my macbook and install windows to install solidworks. Will my mabcook pro be able to operate solid

  • Adding Image Into Form 10g

    created a login form and needed some decoration on a background... seems i browse all over the internet and it says to attached an image into form by using this ; read_image_file('D:\Documents and Settings\All Users\Documents\My Pictures\Sample Pictu

  • Regarding WS_DELIVERY_UPDATE_2 and COMMIT WORK AND WAIT

    Hi Experts, My problem is, when I try to update 1 record more than 1 time, the data(Item delivery quantity)getting cleared  after 2 or 3 attempts. Sometimes it was happening for 5 time and so on.. If i do debugg, it was not happening. I was using Z F

  • Lion OS X interfering with Microsoft Word and Entourage

    I downloaded Snow Lwopard and then Lion so I can utilize Cloud and now my 3 Microsoft programs won't open: Word, Entourage and Powerpoint.  Any ideas why and how can I go back to the way it was?