IDOC to flat file and vice versa

Dear community,
we should send IDOCs to flat files and read plain files and map them to IDOCs.
Is there any comfortable way to do this without doing a huge content conversion for
IDOCs? Exist a SAP standard for such process?
We receive the IDOC as normal IDOC. Would it be more easy to save the IDOCs
directly as flat file on ERP file system??
System PI 7.11
IDOCS: WHSCON, WHSORD and WMMBXY
Regards
Chris
Edited by: Christian Riekenberg on Feb 1, 2012 2:41 PM

Hey folks!
We have a PI 7.31 SPS5 Java-only installation here and are using the module IDOCFlatToXmlConvertor. For single IDocs with one line for the EDC_DC40 header and the others for the IDoc payload the conversion works. But when we want to process multiple IDocs from the same type within one file, we see this error in the log:
Module Exception 'com.sap.aii.af.idoc.exception.IDOCModuleException: No data segments for DOCNUM = ' found, cause: <null>
Are there any requirements how the multiple IDocs have to be structured within the file?
Best regards
Heinrich
Update:
I found out that the module wants each record to contain the corresponding DOCNUM to find the matching records. The non-SAP sender system normally does not set this value. Is there a way to "convince" the module to convert the IDocs nevertheless?

Similar Messages

  • Hi,Can a WAR file be deployed as EAR file and vice versa.

    Hi,Can a WAR file be deployed as EAR file and vice versa.If so what are the changes we need to do.

    hi tel me in detail why u want 2 do that
    why u want to cnvert a web arch into enterp arch

  • IDOC to Flat File and XML ( Need both the Output)

    Hi ,
    My Scenario is IDOC to File .
    I need o/p in 2 format . ie,    1) Flat File 2 ) XML file
    I have a plan to go with Interface determination , 2 IM and what shd be the condition ?
    or Else  2 Receiver detmination  but condition ?
    How to slove this ?
    Need the Output from Idoc in 2 format ( Flat file and XML file )
    Any Blog , Thread ...Tips...etc
    Regards,
    Jude

    Hi Jude,
    Do like this:
    1. Create two inbound Service Interface (with the same target Message Type)
    2. Create separate Operation mapping with the above service interfaces as target (with the same source service interface)
    3. Create Interface Determination and include these two operation mapping (without any condition)
    4. Create 2 receiver agreement (with two separate communication channel) for each of the target service Inetrface. In one channel use content conversion and the other one will give you normal XML output
    Regards
    Suraj

  • IDOC to Flat file and Flat file to IDOC

    Hello Experts,
      I have the following requirement in my current project:
    Third Party Sender sends the data in the in the below XML format via HTTP:
    <?xml version="1.0"?>
    <fxEnvelope>
      <header>
        <message>
          <exchangeID></exchangeID>
          <messageID></messageID>
          <subject></subject>
          <payloadType>IDOC</payloadType>
        </message>
        <from>
          <orgID></orgID>
          <locationID></locationID>
          <messageID></messageID>
        </from>
        <to>
          <orgID></orgID>
          <locationID></locationID>
        </to>
      </header>
      <body>
        <Opaque>
          <DataType></DataType>
          <DataStream></DataStream>
        </Opaque>
      </body>
    </fxEnvelope>
    In the above XML, the Tag <DataStream> is a string which contains the IDOC flat file.
    Now, the scenario is HTTP to IDOC, where the sender sends the above XML payload and PI needs to convert <DataStream> to IDOC XML and pass it on to the receiver R/3.
    But the challange i am facing is converting this <DataStream> tag which contains the IDOC flat file to IDOC XML using a Mapping program.Since both adapters are running on ABAP stack i can not go for Adapter Modules available(We are using PI 7.10).
    Looking for some guidance on the same.
    Thanks in advance.
    Cheers,
    Manasa.

    There are 2 options for you
    In either case, you might need a java mapping to convert the DataStream into String. Use a file adpater to write this string to IDOC-File.
    1) Option1: Write the content of DataStream into IDOC-Flatfile.(java mapping) Pick it from PI to convert IDOC-flat file inot IDOC-XML (using std features of PI) & send it to ECC.
    2) Option2: Write the Content of DataStream to IDOC-Flatfile (accessible to ECC system). Configure WE21 to pick the file from a file port.
    If the datastream was IDOC-XML, then it would have been simpler, it will be a direct communcation from PI to ECC (using java mapping & IDOC adapter).
    Regards,
    Siva Maranani

  • IDOC to HTTP tutorial  and vice versa

    Hello all,
    I am a beginner in PI and I have just configured my first IDOC to file scenario. I am looking to implement an IDOC to HTTP scenario where I create an order in ERP 2004 and the order is sent as an XML file via PI into a suppliers website. I am trying to find a tutorial on how to do that but after looking here in SDN and in google, I couldn't find something helpful. There are plenty of file to idoc and idoc to file tutorials, but not an idoc to http .
    Could you please provide me with some links or some information on where I can start with that. I am also interested on the reverse, i.e. HTTP to IDOC: The supplier sends the invoice in XML format through PI and I receive it in my ERP 2004 system as an IDOC
    Many thanks
    Andreas

    Hey folks!
    We have a PI 7.31 SPS5 Java-only installation here and are using the module IDOCFlatToXmlConvertor. For single IDocs with one line for the EDC_DC40 header and the others for the IDoc payload the conversion works. But when we want to process multiple IDocs from the same type within one file, we see this error in the log:
    Module Exception 'com.sap.aii.af.idoc.exception.IDOCModuleException: No data segments for DOCNUM = ' found, cause: <null>
    Are there any requirements how the multiple IDocs have to be structured within the file?
    Best regards
    Heinrich
    Update:
    I found out that the module wants each record to contain the corresponding DOCNUM to find the matching records. The non-SAP sender system normally does not set this value. Is there a way to "convince" the module to convert the IDocs nevertheless?

  • XML-IDoc to flat file (Release 4.0 and 3.0)

    Hello experts,
    I implemented the guide "[How to Convert an IDoc-XML structure to a flat file and vice versa in XI 3.0|https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/46759682-0401-0010-1791-bd1972bc0b8a]". Now I get a flat file, but it is IDoc-Version V3 (for Release 4.0). Is it possible to create another mapping which creates a Relase 3.0 IDoc instead as shown in transaction WE61 with version 2?
    Best regards,
    David

    Hello all,
    thank you for your answers. But again, it's not about IDoc types!
    Please go to transaction WE61 the last selection on the screen is version (1 for SAP Release 2.0, 2 for SAP Release 3.0 and 3 for SAP Relase 4.0). What the ABAP class from the guide creates is a V3 IDoc for SAP Release 4.0. If you choose the HTML view, you will see, that the versions are different, although the IDoc type is exactly the same. We create Version 3 and we need Version 2.
    Best regards,
    David

  • IDOC to flat File----Problem in File Content Conversion at receiver

    hi experts,
    I am doing a IDOC to flat file secnario.
    My requirment is IDOCXI-Flat file
    Format of flat file is like:--
    Every segment in the IDOC will be converted into a single line of file(without any delimiter). So number of lines in flat file will be equal to number of segments in IDOC.
    I am facing problem in File Content conversion. 
    Please help me out..
    Thanks
    Jaideep

    Check this doc...
    [How To...Convert an IDoc-XML structure to a flat file and vice versa in XI 3.0 |https://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/46759682-0401-0010-1791-bd1972bc0b8a]

  • Multiple idoc to flat file

    Hi,
    i have  a scenario from idoc to flat file.There is two idoc that send message in same file.Without flat file content messages come succesfully.the format should be following:
    at the first  row should be the first idoc,
    at the second row should be the second idoc
    01  1FONEX0045               FONEX0045               FONEX SIVI SABUN 400+850ML FLOWERS                    =>1.idoc
    02  1FONEX0045               8691988000162           8691988000162                                                             =>2.idoc
    01  1DOVE0199                DOVE0199                   DOVE SAC DOKULMELERINE COZUM SAC BAKIM M     =>1.idoc
    02  1DOVE0199                8718114638348           8718114638348                                                               =>2.idoc
    Thanks in Advance
    Nurhan

    Hi,
    You have to MessageTransformBean Module.
    The MessageTransformBean module enables conversion of XML files to flat files and vice versa. You can use this module in the sender and receiver communication channels.
    In receiver communication channel, specify MessageTransformBean module before standard adapter module CallSapAdapter and use
    Module Name: localejbs/AF_Modules/MessageTransformBean
    Module Key : XML2Plain
    Please see the below links, it might be useful to you.
    /people/gabrielsagayaselvam.panneerselvam/blog/2009/12/07/standard-adapter-framework-modules-afmodules-in-pi-71-150part-2
    http://help.sap.com/saphelp_nw04/helpdata/en/24/4cad3baabd4737bab64d0201bc0c6c/frameset.htm
    Regards,
    P.Rajesh

  • Garageband Files on Logic Express and vice versa

    My daughter uses Logic Express at school (sorry, I don't know which version). She has been trying to do her homework on our eMac (OS 10.3.9) using Garageband 1 and her M-Audio midi/usb keyboard via USB.
    Her teacher says that Garageband files should work fine with Logic Express and vice versa.
    The problem is they don't. We have tried importing files, also saving in one programme and opening in the other - all to no avail.
    Presumably we are doing something wrong somewhere. Does anyone know how to get Logic Express to use Garageband 1 files and vice versa, please?
    One more point of information, she saves the files to a 'PikaOne Slim Flycase' 40gb Portable HD to take to school to use on an Apple Laptop type computer (Powerbook?). Both home and school machines appear to be working perfectly with this device.
    She also has some software called 'Logic Hit Kit' but I don't think this is has anything to do with Logic Express. It's files do not work with Logic Express either
    PM6500/300 (603e)   Mac OS 9.1.x  

    That is correct, and you still have your level
    status, it just doesn't show. I read in The Lounge
    (for level 4 & 5) that they were planning to return
    the level status and custom icons to the forum. But
    it has been a long time now, and they haven't. I miss
    my custom icon
    Yes, apparently they intend to at some point. But, they have more pressing things to attend to first, so it might be a while. I have discovered that there's a special forum about this.

  • Flat File and IDoc

    Hi,
      Is it possible to read a flat file and create the sale order through IDoc.  Can i do this by DOC_INBOUND_FROM_FILE without XI?? What file format should i pass??
    Regards,
    Kit

    Hi  ,
    you can create Sales order through IDoc. IDOC_INPUT_ORDERS
    At a high level, the IDOC processing executes in the following manner:
    1.     Interpret IDOC header segments and captures organizational, customer master and purchase
                   order header details. Performs user exits for each segment to process customizations to data
                     processing.
    2.     Interprets item level segments and captures item level details like material information. Again,
                   it performs user exits for each segment.
    3.     Sums up the order data and determines the posting criterion viz. creating order with reference
                      etc.
    4.     Builds up batch data communication sequence (BDC) with respect to the required screen
                  sequence of posting a sales order.
    5.     While building up the BDC data, system performs user exit to process customizations to BDC
                    data.
    6.     Calls transactions VA01 using the BDC data.
    7.     If the processing fails, an appropriate workitem is generated for workflow processing.
    if you give me brief i can help you out more.
    if helpful REWARD points
    Thank you .
    Regards
    Ramana

  • Mac OS 10 can't see files on HD coming from OS 9 and vice versa?

    Hello, all!  Got a TiBook 1Ghz with a 255 GB HD which I've partitioned in half, one for Tiger/OS 9 and one for Leopard.  Problem:  Any file placed on Vol 2 in OSX is invisible in OS 9 and vice versa, so one writes over the other.  Vol 1 works fine.  Tried reformatting, disk repair, DiskWarrior 9 and 10, re-installing all the operating systems.  Suggestions?  Thanks!

    Hi, kennethfromtoronto & BGreg!  I do know that OS  9 is not supported by Leopard, however I'm not talking about running 9 in Classic.  This TiBook will run 9 by itself, but when I run OS 9 it is from Volume 1 which also has Tiger installed.  I can boot from Tiger or from OS 9 from Volume 1 and they both run just fine.
    The problem is that when do I boot from OS 9, it can't see the files on Volume 2 that were placed there under OS X Tiger.  Conversely, when I run Tiger, the files I put on Vol 2 while running OS 9 are not visible.  It's like I'm running a parallel universe.  Unfortunately, this allows one system to overwrite whatever was put on the volume from the other system, and vice versa, with the net effect that I don't dare run OS 9 for fear of overwriting data on Volume 2. 
    Also when I do run Leopard from the second volume, it also cannot see any files on Volume 2 that were put there under OS 9.
    Note that with Volume 1 there is no visibility problem, no matter which of the three systems is running.  It happens with the second volume, whether it has an operating system installed on it or not.
    Usually I am good at figuring this stuff out, but you see how confusing this is...  My thinking is there might be a bug in the Apple formatting software?  I used the Disk Utility from my external hard drive which runs Leopard.
    Makes a good puzzle to solve, anyway...  Thanks for the help!
    DQM

  • Data transfer between SAP & Java and Vice versa using IDOC Process

    Dear Experts,
            We are working on one of the good requirement related to data transfer between SAP and Java software. Client requirement is, they want to transfer the data in both the ways (from SAP --> Java and Vice versa also).
    In detail is, after sales order creation using one custom program loading plan details will be calculated. Once loading dates are confirmed then, user will release the sales document to transfer the data from SAP to Java using "Outbound IDOC processing". Similarly in that JAVA software some shipment details will be performed, once completed from JAVA software again details needs to be pumped back to SAP as "Inbound IDOC Processing".
    For this fields are already identified from external software SAP and we are looking for the same to perform the steps in SAP.
    At this stage, I need your expert opinion  / feedback how to go  about at this stage.
    Meaning,  
                     1. What are the customizing steps needs to be done in SAP..?
                     2. How to trigger the :Outbound IDOC process" once the documents are "Released" from custom transaction
                     3. How to create the link between SAP and JAVA to transfer the data between these 2 software
                     4. How to trigger the "Inbound IDOC Process" from JAVA software to SAP and how to store the data in SAP
    Experts, please give your feedback in terms of reply or by sending the step by step process to fulfill this client requirement.
    Thanks for your cooperation.
    Regards,
    Ramesh

    Maybe too many open questions in the same document.
    Maybe you should repost a more specific question in a technical forum.
    This looks like a small project where you already know what you want, maybe you should contract a technical specialist so he proceeds to the implementation!

  • How to read an IDOC flat file and send it to XI

    Hi,
    I'm looking for a way to read a complicated Idoc structured flat file sent to XI by a legacy system and then pushing that data to and R/3 system. Can anyone recommend a good technique?
    Thanks,
    Steeve

    hi steven....
    this shud help u...
    for FileXIIDoc
    File->XI->IDOC (how to start?)
    also check this blog for specifying adapter specific identifiers in this scenario
    These are steps to follow:
    STEPS IN DESIGN
    1. Import idoc from the SAP System (SAP02) through imported objects.
    2. Create Data Type, Message Type, Message Interface for the Outbound File.
    3. Create Message Mapping with file Message and idoc (Matmas04)
    5.Create Interface mapping between File Interface and the idoc.
    Steps to be followed in Creation of Technical and Business System
    Technical System
    In SLD, click on technical landscape->New Technical System->WebAS ABAP.
    Business System.
    1.Goto Business Landscape->New Business System->Name the business system.
    2. Choose the technical system that needs to be attached->WebAS ABAP->Technical System Name.
    Preconfiguration steps for transfer of data to IDOCS
    1.Create a RFC Destination in SM59 of XI Server of type.
    2.In transaction IDX1 ,create a port for the client of XI server.
    3. The port has to be displayed in the idx2 transaction and we should be able to view the idoc’s which we imported through integration repository.
    Steps in Configuration
    1. Goto service without party, right click->Assign a business system.
    2. Choose the business system to be added.
    3. Create a File Sender Service with communication channel for the same.
    4. Create an idoc receiver channel under the business system. Mention the RFC Destination and the port created for the same.
    5. Mention the logical Name in the Service->Adapter Specific Parameters of both the File Sender Service as well as the business system.
    6. Make the Sender Agreement for theFile Sender with communication channel.
    7.Create the Receiver Determination and Interface Determination for the business system.
    8.Create the Receiver Agreement for the Business system.
    TCODES for File>XI>IDoc
    SM59-rfc destination on recving side
    IDX1-port on recving side
    IDX2-load metadata
    Bus. service adapter specific Identifiers-->Logical sys name (check this blog:/people/michal.krawczyk2/blog/2005/03/29/xi-error--unable-to-convert-the-sender-service-to-an-ale-logical-system )
    we05-IDoc status records
    BD54-Create Partner Number
    We20-Create Partner Profile
    and also go thru this blog...
    /people/anish.abraham2/blog/2005/12/22/file-to-multiple-idocs-xslt-mapping
    hope it helps....
    regards...
    vishal
    /people/michal.krawczyk2/blog/2005/03/29/xi-error--unable-to-convert-the-sender-service-to-an-ale-logical-system

  • How to link idoc with its corresponding documents and vice versa...

    Hello Experts,
    What are the tables, transactions, etc that can link a certain document(e.g. PO, GR, invoice) to its IDoc and
    vice versa.
    Thank you guys and take care!

    Hi,
    The Message Control parameters from the partner profiles must also match the corresponding
    fields in the output type. These parameters include:
    u2212 Application
    u2212 Partner
    u2212 Partner function
    u2212 Output type
    Tcode  - NACE  (Output Control)
    Tables - SRRELROLES  (Object Relationship Service: Roles)
    Message Control is a mechanism by which documents are output based on certain conditions.
    1) The application id, communication structure and o/p determination procedure are responsible for triggering IDocs corresponding to a particular application document. For this to happen message control settings have to be done.
    2) Message Control u2013 also referred to as output control or conditioning technique u2013 is a cross-application component used as a service program in several areas. The basic concept behind Message control is to generate and manage outputs from an application and control their timings and medium of exchange.
    3) Message control settings can be done via transaction NACE or via transaction NACO.
    4) Starting point in message control in the u201COutput Determination Procedureu201D (Procedure within NACE txn.). Depending upon the configuration setting in SPRO this procedure is determined.
    A procedure defines a set of possible outputs for an application. We can define several procedures for an application, but only one can be configured as
    active (i.e. for a particular transaction document within an application only one procedure will be determined based on configuration settings).
    Eg->
    a) For Delivery (txn. VL01NO) the document type setting in configuration (SPRO -> Logistics Execution -> Shipping -> Deliveries -> Define Delivery types) determines the procedure.
    So whenever we save a document of particular application (of particular application id) and of particular document type, the particular o/p determination procedure is triggered.
    b) For sales, SPRO -> Sales and Distribution -> Basic Functions -> Output Control -> Output Determination -> Output Determination Using the Condition Technique.
    5) In the transaction NACE we can see that corresponding to application id (say u2018V2u2019 (shipping)) various procedures are defined:
    6) Before making the entry of the output type corresponding to a particular procedure, we have to define it with its attributes.
    The output type defines the characteristics and attributes of the output itself. We can access the output types on transaction NACE by selecting an application and clicking the Output type button.
    7) Access sequence defines a sequence in which business rules are checked for proposing an output type. It has following attributes:
    - A set of business rules or conditions.
    - A sequence in which the rules or conditions are checked.
    - A requirement that checks for business rules using ABAP programs.
    - An exclusive or inclusive strategy.
    We can access the access sequences on transaction NACE by selecting an application and clicking the Access Sequences button.
    Business rule 1 is based on SOrg./Distrib.Ch/Division/Customer. Business rule 2 is based on Sales Organization/Customer Number. Each business rule is, effectively, a set of fields defined in a condition table.
    8) Condition table specifies the key fields for a business rule. Hence for Business rule 1 the key is Sales Org., Distribution Channel, Division and Customer.
    9) Condition records are inserted in the condition table. The transaction is evaluated with the key (of the condition table based on business rule) and if the transactional data matches with the condition record the output is proposed.
    Condition records are defined at last.
    10) Several programs and tables are part of Message Control. For EDI, the following tables and programs will frequently be dealt with:
    *NAST - This table has an entry for the processing program used for an output type.
    *TNAPR - This table has an entry for the processing program used for an output type.
    *RSNAST00 - This program is used to process entries in the NAST table.
    *RSNASTED - This processing program exists for each output medium. ALE_PROCESSING is the routine in the RSNASTED program to process ALE outputs.
    11) Final overview of the components used in Message control to propose outputs.
    12) After doing all the settings for message control, the partner profile setting for this ALE scenario needs to be accomplished. We need to add the following entry to the outbound parameters of the partner profile:
    13) One important question that arises at this juncture is, how is the partner profile determined from the output type is case of ALE?
    This is information is stored in table EDP12 (Partner Profile: Outbound with Message Control). Based on the Partner type of receiver (RCVPRT), output type (KSCHL) and Application for message conditions - without value table (KAPPL), the Partner number of receiver (RCVPRN), Outbound process code(EVCODA), Message type (MESTYP) and other related values are determined.
    Regards
    Pugazhenthi.P

  • Im new to Mac and wanted to know what is the easiest way to transfer files from a mac computer and mac extenal hardrive to windowns and vice versa?

    Im new to Mac and wanted to know what is the easiest way to transfer files from a mac computer and mac extenal hardrive to windowns and vice versa?

    For small amount of files, a regular USB stick or drive, it's already formatted with a MBR and FAT32 most likely which works both on PC's and Mac's.
    External drives if you need more space.
    However FAT (or Fat32 or MSDOS) has a 4GB file size limit. So if your transfering files bigger than that then you need to format it exFAT on the Windows machine.
    Vista and Win 7 can do this, Windows XP one can download a free exFAT upgrade from Microsoft.
    Mac's can read/write the MBR and FAT/exFAT (10.6.5 and later) formats, it's best to format it on the Windows machine, even though the Mac can format it too, it's better to do it on Windows then take it to the Mac to confirm.
    Rack your brain here on it.
    https://discussions.apple.com/message/16317478#16317478

Maybe you are looking for