Flat File to Delivery IDOC scenario

Dear All,
I am having one scenario in which I am having the flat file (.txt) of the Delivery Idoc and now I want to convert that flat file into a Delivery Idoc with the required data.
Kindly suggest me some good blogs which gives the step by step process for doing this scenario.
Warm Regards,
N.Jain

Hey Nishu,
You have  to use File Content Conversion Paramters to acheive this.
http://help.sap.com/saphelp_nw04/helpdata/en/e3/94007075cae04f930cc4c034e411e1/content.htm
http://help.sap.com/saphelp_nw04/helpdata/en/2c/181077dd7d6b4ea6a8029b20bf7e55/content.htm
You can Follow the following blogs
/people/venkat.donela/blog/2005/03/03/introduction-to-simple-file-xi-filescenario-and-complete-walk-through-for-starterspart2
/people/venkat.donela/blog/2005/06/08/how-to-send-a-flat-file-with-various-field-lengths-and-variable-substructures-to-xi-30
/people/jeyakumar.muthu2/blog/2005/11/29/file-content-conversion-for-unequal-number-of-columns
/people/shabarish.vijayakumar/blog/2006/02/27/content-conversion-the-key-field-problem
Or juz post your sender datatype structure some one might give u exact fcc params.
Hope itz Helpfull.
<b>Cheers,
*Raj*
*REWARD POINTS IF FOUND USEFULL*</b>

Similar Messages

  • File Service to IDOC Scenario

    HI ,
    I am trying file service to IDOC scenario and iam getting following error "Unable to convert sender service FilesService_FILE2IDOC to an ALE logical system".
    Here file has to be read and IDOC has to be posted in SAP system. Sender is not an SAP system / 3rd Party system ...itz an FILE  sender service.
    Settings i have done:
    In Message Mapping in target IDOC structure i have disabled Control record
    In integration directory IDOC Receiver Communication channel i have not selected "Apply Control Record values from Payload".
    In receiver determination in header mapping i have put sender sevice "FilesService_FILE2IDOC ".
    But still i receive the same error.
    I do not want to send control record parameters in Message Mapping .
    Pls throw some light on this ....
    Regards
    Sri

    Hi Sridhar,
    Regarding your error, below is the answer...
    When you create the business system (in the SLD) you assign a "logical system name" or "ALE name". That is used as the ALE name for transporting IDOCs, and the sender system.
    You have to also maintain this name in the R/3 System (tx. SALE, WE20), because IDOC will be noted as arriving from that system.
    You also told that you dont want to pass the control records value....Do this, just deactivate the control records segments in your message mapping... let me not explain it further.... just check these blogs below for the same,
    /people/sravya.talanki2/blog/2005/12/02/manipulating-idoc-control-records-from-payload
    /people/michal.krawczyk2/blog/2005/09/01/xi-idoc-adapter--edidc40--demystified
    And also go thru the following links to get a better idea about partner profile:
    http://help.sap.com/saphelp_nw04/helpdata/en/dc/6b833243d711d1893e0000e8323c4f/frameset.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/dc/6b7cd343d711d1893e0000e8323c4f/frameset.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/32/692037b1f10709e10000009b38f839/content.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/5e/b8f8bf356dc84096e4fedc2cd71426/frameset.htm
    I hope this helps you solve your problem.
    Regards,
    Abhy

  • File to Multiple Idocs scenario. Pls help

    Hi All,
    For Single File to Multiple Idocs scenario i am referring blog --
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/877c0d53-0801-0010-3bb0-e38d5ecd352c
    Suppose my source file is
    AAA, BBB,CCC
    111,222,333
    ZZZ,ZZZ,ZZZ
    I want to make 2 IDOCS for the first 2 records (AAA, BBB,CCC   and  111,222,333)
    and do not want to make IDOC for the 3rd record  -- how to achive this.
    Regards

    Hi,
    If the condition is like, for 'AAA' and '111', IDocs to be generated, then do as follows.
    If IDOCs are of same type.
    1. Value
    > Equals -
    > createIf -
    > IDOC
       Constant('AAA')
    2. Value
    > Equals -
    > createIf -
    > IDOC
       Constant('111')
    3. Value
    > Equals -
    > not -
    > createIf -
    > IDOC
       Constant('ZZZ')
    If 2 IDocs are of differnet types,
    create different mapping programs with same logic.
    If 2 IDocs are to be generated based on the record no in the file rather than the first field value, i think you can go for Global container.
    Refer these,
    [http://help.sap.com/saphelp_nw04/helpdata/en/ee/bf9640dc522f28e10000000a1550b0/frameset.htm]
    [http://help.sap.com/saphelp_nw04/helpdata/EN/49/1ebc6111ea2f45a9946c702b685299/content.htm ]
    [http://help.sap.com/saphelp_erp2004/helpdata/en/75/8e0f8f3b0c2e4ea5f8d8f9faa9461a/frameset.htm]
    thanks.
    Edited by: P.Ravi Varma on Apr 22, 2009 10:27 AM

  • Creating a flat file in the IDOC format

    Hi everybody,
    Need help.....urgently. Can somebody please tell me how to create a flat file in the IDOC format? I am creating a bill of lading/Documentary payments (EDI 858) and can't figure out a way to write the data generate through the report in a flat file in IDOC format. My deadline is right around the corner and I need help.
    Thanks,
    M

    Hi Minal,
    I still don't understand your question.
    So, you have a report which selects data and puts it into an internal table.  This part looks fine.
    You want to create a flat file?  Ok, to create a flat file on the application server then use the commands OPEN DATASET, TRANSFER, and CLOSE DATASET.  To create a flat file on the presentation server then use the FM GUI_DOWNLOAD (or the GUI class, I forgets its name for the moment).
    In both cases you should build up an internal table which has the exact structure required for your (EDIFACT?) EDI message, and then use the appropriate method to write the file.
    If the following steps are manual then there is nothing more for you to do.
    I don't see any need to use Idoc technology, or make any reference to it in your solution.
    I hope that helps.  If not, please be more specific when asking your questions.
    Brad

  • 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

  • Flat file to several IDOC instaces

    Hi everyone,
    I have the follow scenario: I will have a Flat file with a common structure (Header, Detail ) this structure will be repeated several times into the flat files, I have to send several times an IDOC this depending of  a change in one field in the header strucutre on my Flat File.
    I know how to read the flat file and how to send an IDOC but I don't know how to send many IDOCs and How to know when a field change in the structure.
    Could anybody help me with this? or send me a Weblog with a similar scenario.
    Thanks

    In your File Adapter under the "Content Conversion Parameters"
    Document Name           Messagetype Name
    Document Namespace      Namespace Name
    Recordset Name           root
    RecordsetStructure      Header,,Detail,
    Recordset Sequence      Ascending
    Keyfield Name           Field1
    Header.fieldNames       Field1,Field2,Field3
    Header.fieldFixedLengths 1,1,25
    Header.separator        'nl'
    Header.keyFieldValue     H
    Detail.fieldNames       Field1,Field2,Field3,Field4
    Detail.fieldFixedLengths 1,1,5,25
    Detail.separator        'nl'
    Detail.keyFieldValue     D

  • 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- XI- Multiple IDOCs scenario

    Hi,
    I am working on File->XI->IDOC scenario. I have a single source file and I need to map it to two IDOCs and post them to ECC. The order of posting is not an issue since it is taken care of by ECC.
    I need help (detailed) on achieving this in the best possible way (using/without using BPM).
    Thanks,
    Guru
    PS: I went through the following blog:
    /people/jin.shin/blog/2006/02/07/multi-mapping-without-bpm--yes-it146s-possible
    But as per this blog, multi mapping is not possible with IDOC as the IDoc adapter is outside the Adapter Engine.

    As Jaishankar suggested,
    going for separate mapping is a better n simple options.
    Source Message Interface Mapping 1> IDOC1
    Source Message Interface Mapping 2> IDOC2
    Since you are sending the IDocs to the same system,
    One rcvr in rcvr determination, without any condition.
    in interface determinations, you have 2 inbound interfaces, and corresponding Interface mappings.
    Its a simple n straighforward approach.
    Regards
    Pushkar Anand

  • File to Multiple Idoc scenario using FCC

    Hi All,
    I am working in a file to idoc scenario. Here input is a  fixed length file having  Header and Item details which will repeat for many times.The number idoc in the target is based on the number of header in the input field. I have created a source structure with header as 1..unbounded and i have map the header with the target idoc.
    In configuration part
    Recordset Structure  Header,9999,Item,9999
    I am facing an error in communication channel as
    "Conversion of file content to XML failed at position 0: java.lang.Exception: ERROR consistency check in recordset structure validation in last recordset"
    Please help me to resolve this issue. Thanks in advance.

    Hi,
    Source structure is
    DATA         1...1
      Record      0...unbounded
          Header  0...unbounded
          Item       0...unbounded
    Here i am mapping Header to the target Idoc
    In configuration
    RecordSet Name: Record
    RecordSet Structure:Header,9999,Item,9999
    RecordSet  Sequence:Varaible
    Key Filed name : RecordType
    Header.fieldFixedLength  -
    Header.fieldNames          -
    Item.fieldFixedLength      -
    Item.fieldNames               -
    Header.keyFieldValue   : H
    Item.KeyFieldValue         :I
    Header.lastFieldOptional   YES
    Item.lastFieldOptional         YES

  • Flat file to multiple IDOCs

    Hi experts,
    I have a bit of a problem here wit a flat file to IDOC interface.
    My input CSV file structure (shortened) is as follows -
    <?xml version="1.0" encoding="UTF-8"?>
    <ns0:POINBOUND_MT xmlns:ns0="urn:xx:xi:dwn:xx:pf:xxx:poinbound:100">
       <Record>
          <Row>
             <PO_HEADER_ID/>
             <TYPE_LOOKUP_CODE/>
             <LINE_NUM/>
             <AMOUNT_LIMIT/>
          </Row>
       </Record>
    </ns0:POINBOUND_MT>
    the target side is an idoc - PORDCR1.PORDCR102.
    in the input file, for each row the PO_HEADER_ID field will have repeated values. the structure for eg.-
    PO_HEADER_ID < other fields> < otherfields> ...
    12345 <other fields>..<..  >
    12345 <other fields>..<..>
    12345 <other fields>..<..>
    56789 <other fields>..<..>
    56789 <other fields>..<..>
    Now i need two idocs ( 2 distinct header values) on target side - the 1st idoc will have first 3 line items and 2nd idoc will have the last 2 line items.  have already edited the IDOC in xsd format to make it unbounded.
    <b><u>Problem</u></b> - i am able to create two idocs by handling contexts(splitbyvalue and a UDF), but with the line items its not working i.e. <u>the first idoc gets the 3 line items created but the 2nd idoc does not have any!</u> 
    my mapping for line items is -
    PO_HEADER_ID <-> splitbyvalue(value changed) <-> count <---> UDF (for result.addvalue using count)  <----->  lDOC LINE_ITEM node.
    This logic does not work incase i need to create more than one idoc on the target side, it only works for the first idoc..so wat can i do??
    Plz help.
    thnx in advance!
    Raju.

    Hi Raju,
    check these links...
    /people/anish.abraham2/blog/2005/12/22/file-to-multiple-idocs-xslt-mapping
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/877c0d53-0801-0010-3bb0-e38d5ecd352c
    Sachin

  • Guarantee EOIO Processing in File-RFC-RFC-IDoc Scenario

    Looking for some opinions on the following set up we've got.  We're trying to build QoS EOIO on a scenario that goes File Sender->RFC and then RFC->IDoc.  My question is basically have we effectively ensured that our scenario will be EOIO from file to IDoc.  We want the first record in the file to always be the first created IDoc, the 10th record in the file to always be the 10th IDoc created etc.....  We also want to make sure that if we encounter an error at any point that all subsequent processing stops and waits until the problem is resolved.  We've successfully completed some steps but my biggest concern is in the area between where XI sends the data to SAP1 via RFC and the resulting return RFC from SAP1.  I'm thinking we may not be quite there yet and would be interested to hear what others thought.
    We're on SP15.  The scenario goes like this (no BPM):
    1) We have a legacy system LEG1 that we pick files up from using the Sender File adapter.  This step will take the file from LEG1 into XI and map it to an SAP remote function on SAP system SAP1.  We set QoS on the file adapter to EOIO.  Our interface determination for the File to RFC component is set to QoS of "Maintain Order at Runtime".
    2) XI makes the RFC call to SAP1 (6.20) using an RFC receiver adapter.  The called function then processes the data and returns the data back to XI using another remote function call.  This function call is of type tRFC where we call the function "in background task" and issue a commit after the RFC call.
    3) We receive the data into XI from SAP1 using the RFC sender adapter.  XI maps it to our IDoc layout and sends it onto another SAP system called SAP2.  Again here our interface determination QoS is set to "Maintain Order at Runtime".
    4) XI passes the IDoc onto SAP2 (7.00) using a receiver IDoc adapter. The paramter Queue Processing is turned on.

    About EOIO in qRFCs, actually this is quite a polemic topic.
    There is something you could do, allright, but it is controversial whether you could properly call it "EOIO" or not.
    Refer to this thread for further discussion: use EOIO on Sender RFC and outbound ABAP proxy calls
    Supposing you call the other RFC before you commit work in the receiver RFC, and supposing you could have EOIO at 2nd RFC (sender RFC), all these assumptions could mean that you would guarantee EOIO end-to-end. But they are just assumptions.
    You have to try it and stress test the scenario to guarantee the validity of this design.
    One other approach would be a BPM with all steps in one single transaction (check BPM transaction handling). The steps would be:
    File -> sync RFC -> Idoc
    where the response of RFC should be the necessary information for triggering the IDoc, and all send steps would be in EOIO mode (set queue name in Send steps). Also, file sender adapter QoS should be set to EOIO.
    But I'm also not sure that this will guarantee EOIO end-to-end (possibly not...)
    Good luck.
    Regards,
    Henrique.

  • File to multiple idoc scenarios depending on finput field value

    Hi,
    i have a file to idoc scenario.
    depending on a particular field of the file i have to trigger a single idoc (with all the records in the file)or multiple idocs  (for each record in the file ).
    for example,
    the file has 5 records-
    2 records have field value A (create 1 idoc for all As)
    3 records have field value B (create 1 idoc for each B)
    so in this case 4 idocs (1 for all A, and 3x1 for B) are created
    What is the best solution ?-
    1. to have several outbound idoc interfaces and check each interface mapping for field value (A or B) ?
    this solution seems like overwork to me
    2. handle this in mapping ?
    in that case will UDF be better or ABAP mapping
    3. any other way ?
    Thanks in advance

    Hi,
    if you have one IDOC type you can use ABAP mapping
    this way you will handle everything in tables
    and you will be able to post one IDOC (bundled)
    with all IDOCs inside
    also if you use ABAP mapping you will be able to incorporate changes
    easily in the future I believe
    for idoc bundling:
    <a href="/people/michal.krawczyk2/blog/2006/10/11/xi-new-book-mastering-idoc-business-scenarios-with-sap-xi"><b>Mastering IDoc Business Scenarios with SAP XI</b></a>
    Regards,
    michal
    <a href="/people/michal.krawczyk2/blog/2005/06/28/xipi-faq-frequently-asked-questions"><b>XI / PI FAQ - Frequently Asked Questions</b></a>

  • Sales Order - Outbound Delivery IDoc scenario.

    Hi Friends,
    I have the below urgent requirement. I would be gratful, if someone suggest possible options.
    Scenario: This is related to Sales order to Billing scenario.
    We are creating Sales orders by using ORDERS05 Idoc. After the Real goods despatch happens at legacy system, we will be getting despatch feed (IDoc) for outbound delivery trigger. Here if all sales Order items are complete, the system is creating Outbound delivery by using this IDoc and then PGI will follow. This is Ideal scenario.
    Practically what happening is, our sales orders are created with few incomplete items (Ex: Net price missing) because they are created via ORDERS05 Idoc.( Manually, we can't create sales order with incomplete items, unless we force the system to do so). When the Out bound delivery IDoc triggered, it will pick up only completed items and creates partial delivery and becomes 53 status. Now the sales order is left out with open and incomplete items.
    Now our aim is how to make this outbound delivery IDoc fail, if this is not able to create delivery for all items?? (I mean, if the sales order items are incomplete, the delivery Idoc must fail. So later, if sales order becomes complete, this Idoc can be reprocessed again) How can we make this scenario possible??
    Expecting your thoughts and inputs.
    Regards,
    Kaleeswaran

    HI,
    I suggest you to think of similar solution as below.
    1.As your issue is at order (few items are incomplete with Pricing issue or some other issue), at sales order level while saving each sales order write the code in user exit_save_document_prepare to check if any items exists as incomplete. if yes then populate a delivery block in the sales document header.(you can use a new delivery block to distinguish the reason for the block)
    2. While creating delivery for the order through Idoc since the incomplete orders have a delivery block at the sales document header level SAP wont create delivery for the entire Order.
    3.Handling this delivery block at sales order header: when ever a sales order is popluated with this new delivery block triggere a workflow which will shoot a mail to your End user team or customer representative team. they will correct the issue in the order and remove the delivery block. if you dont want to go with a workflow then you need to incorporate a process to remove the delivery block in the sales order
    Thanks,
    Srini

  • FM to create a flat file in given IDOC type format

    Hi,
    I need to create a flat file having IDOC format.
    I have data in some other source file.
    Which function module can be used for the same?
    Could you pls provide some sample code?
    Appreciate the help.
    Thanks.
    -Shreyas

    My Exact requirement is:
    I have some data in a source file.
    Now I want to create a flat file while which should be in a standard IDOC format(WMMBID02) so that I can process it later using IDOC processing say EDI_DATA_INCOMING or any appropriate FM which will process IDOC later.
    I dont want IDOC to be created in the system right now. I just need to reformat my source file into a standard IDOC format flat file.

  • File to multiple IDOCs scenario with the same receiver system

    Hi guys,
    I have to design and implement the following scenario:
    I will receive one file with many lines (Records) with data for materials, quantities, operations etc..
    Based on the values of some fields of each line, I will have to create an IDOC for each material.
    For example:
    if operation type = "INSERT", and Labor = 001 then create 3 Idocs of type MBGMCR with movement types=101, 261,311 that have to be posted one after the other to the same receiver system.
    else if operation type = "INSERT", and Labor <> 001 then create an Idoc MBGMCR with movement type=311 and plant = 1001.
    else if operation type = "Delete", and Labor = 001 the created 3 Idocs MBGMCR with movement type=312, 262 1002 and post them serially to the same receiver system.
    else if operation type = "Delete", and Labor <> 001 the created 1 Idoc MBGMCR with movement type=312.
    All IDOCS are posted to the same SAP R/3 system. We do not care about the sequence, except for the cases where 3 IDOCS are created.
    I am trying to think of a good design in performance terms.
    It is obvious that I will need BPM for sure.
    I am thinking of creating a mapping program that will produce 4 message types for the different cases from the initial file and then create a different message mapping for each case from the message type to the IDOC.
    I am asking you if I have to include everything (mappings) in BPM with a "fork" step?
    Or shall I produce only the 4 message types and then post them to R/3 and execute the mappings in R/3?
    Best Regards
    Evaggelos

    hi,
    >>I am thinking of creating a mapping program that will produce 4 message types for the different cases from the initial file and then create a different message mapping for each case from the message type to the IDOC.
    To me this seems to be the right solution.
    here u will create different message mappings and write them sequentially in interface determination. the multi mapping will then be utilised in transformation step in BPM.
    thus if this is the only requirement there is no need of using a fork step.
    [reward if helpful]
    regards,
    latika.

Maybe you are looking for