Receiver File Adapter - Content Conversion

I don't quite get this:
I have a structure
<?xml version="1.0" encoding="UTF-8"?>
      Bla bla bla
I want to convert this to a flat file with a line containing
Bla bla bla
In te receiver file adapter I define the following:
In the 'Content Conversion Parameters'
  Recordset Structure : AnElement2
  Name                         Value
AnElement2.addHeaderLine         0
AnElement2.fieldSeparator        'nl'
AnElement2.endSeparator          'nl'
This results in an Empty file each time indicating some error somewhere.
What am I missing?

Hi Andre,
Just check the link <a href="">File content conversion</a>
Also check out this web log <a href="/people/venkat.donela/blog/2005/03/03/introduction-to-simple-file-xi-filescenario-and-complete-walk-through-for-starterspart2 to TXT</a>
Is there any error log shown in File adapter ?
Message was edited by: keith thompson

Similar Messages

  • Receiver File Adapter Content Conversion Problem.

    Hi All,
    I am getting in receiver file adapter due to content conversion setting. Problem is that all the fields coming in file adapter are optional. In content conversion , i have specified fieldfixedlengths. So whenever any optional field is not present , it fails . How should we handle it? is there any option to declare fields as optional, I know that is the there for sender adapter. But no. of fields is also very large, so putting each and every field as optional is very time consuming.
    What should i do?
    Ranjeet Singh.

    Hi Daniele,
    Instead of using the standard funciton , i created a UDF for handling this situation.
    My logic is UDF is like
       //write your code here
    int Size = Integer.parseInt(Truncate_Size);
    String Return_Value = "";
         if  (!("".equals(Input)) )
              if  (Input.length() > Size )
                   Return_Value = Input.substring(0,Size);
                   Return_Value = Input.substring(0, Input.length());
              for(int i = 0; i< Size ; i++)
              Return_Value = Return_Value + " " ;
    return Return_Value;
    SO in this case also , it should be able to handle empy source element. But it is not working.

  • Receiving file adapter content conversion issue

    Could someone please help me with a Receiving file adapter issue?
    My output structure is something like this:
    Vendor_file_MT (occurence 1)
    --Recordset (occurence 0..unbounded)
    Vendor (occurence 1)
    My content conversion is very simple:
    Recordset Structure: Vendor
      Vendor.fieldFixedLengths   30,30,30, (...) ,1,27
      Vendor.fixedLengthTooShortHandling   Cut
      Vendor.endSeparator   'nl'
    If I don't do the content conversion, it works fine, I get all the fields in the XML format.
    When I do the content conversion however, I get multiple lines but only the very first field of each line.
    What could be the problem? What am I missing here? Any idea?
    Your help would be much appreciated.

    Its little strange that its not working even after adding that.  Did you check the receiver channel in your RWB for any logs. Add the statement in my previous post and Also try to clear the Cache and activate the channel again..See if it works
    Glad it worked
    Edited by: Guru on Apr 21, 2008 3:15 PM

  • Receiver File adapter content conversion using StrictXml2PlainBean

    Hi All,
    For receiver file adapter i am using the module StrictXml2PlainBean, and also i mentioned the module configuration like this
    parameter name                              parameter value
    recordTypes                                  Header,TransactionHeader,TransactionDetail,TransactionTrailer,FileTrailer
    FileTrailer.endSeparator                |\n
    FileTrailer.fieldSeparator               |
    Header.endSeparator                   |\n
    Header.fieldSeparator                  |
    TransactionDetail.endSeparator   |\n
    TransactionDetail.fieldSeparator  |
    TransactionHeader.endSeparator |\n
    TransactionHeader.fieldSeparator |
    TransactionTrailer.endSeparator  |\n
    TransactionTrailer.fieldSeparator |
    But when i send the idoc, The receiver CC is throwing an error
    Message processing failed. Cause: Invalid structure name encountered during conversion: Transaction at XML element MT_DeliveryOrder,Transaction
    My actual structure is
       Header  0...1
       Transaction 0....Unbounded
          TransactionHeader  1..1
           TransactionDetail     0...unbounded
            TransactionTrailer  1...1
       FileTrailer  0...1
    The module is checking for the Transaction node,but i require the rest 3.
    Same configuration i have done successfully with FCC without using the module....
    So can any one suggest me where i am missing... why the module is pointint towards, the Transaction cant i ignore this node . and continue with the rest???
    Edited by: sridhar reddy kondam on Aug 10, 2009 12:35 AM

    Hi Rajesh,
    The same FCC configuration was working fine with FCC and when i am using this module configuration i am getting the prob...
    In the file i need the Header,TransactionHeader,TransactionDetail,TransactionTail,Filetrailer
    my sample output file is
    <?xml version="1.0" encoding="UTF-8"?>
        <TransactionHeader> 1..1
         <TransactionDetail> 0...Unbounded
    <FileTrailer> 0...1
    Any suggestions will be great help...
    I think i need to go with other options without using this module....
    Edited by: sridhar reddy kondam on Aug 10, 2009 6:03 AM

  • Blank line in receiver file adapter content conversion

    I am using a receiver file adapter. Everything is working fine. Except that a blank line is put by the file adapter between each records. It is a flat file format.
    I have used the stting below. How do we remove the blank line?
    ACCTHDR.fieldFixedLengths 1,7,4,9,8,665
    ACCTHDR.absoluteRowWidth  694
    ACCTHDR.addHeaderLine 0
    Sachin K

    The default value is a line break (no explicit separator after the last column; instead the structures are arranged line-by-line).
    If you enter a character string here, the system adds it to the last column as a closing character. You can also make this specification in addition to NameA.fieldFixedLengths. To include a line break following the closing character, you must explicitly define it by attaching ´nl´ (including the quotation marks) to the string.
    Agasthuri Doss

  • File Adapter - Content conversion parameters at Receiver

    Hi all,
    I'm trying to translate a XML message to a text line file.
    My XML message is this:
    <?xml version="1.0" encoding="UTF-8"?>
    <ns1:Proveedor_100011 xmlns:ns1="">
    I only want to write to text file the "root" TAG content.
    I try different "Content conversion parameters" in the integration builder (configuration)
    For example:
    RecordSet Structure: root
    root.addHeaderLine   0
    root.fieldSeparator  ;
    root.endSeparator    ;
    but the better result is all XML content.
    Can someone tell me how to skip "Config" TAG and only write the "ROOT" one?
    I'll apreciate any help.
    Thanks in advance,

    Hi Sravya,
    I've tried again without better luck.
    I change the root element of my message from
    Proveedor_100011 to Proveedor100011. (removed underscore)
    I created the next message as in your weblog:
    <?xml version="1.0" encoding="ISO-8859-1"?>
    <xsd:schema xmlns:xsd="" xmlns="" targetNamespace="">
    <xsd:element name="Proveedor100011" type="Proveedor100011" />
    <xsd:complexType name="Proveedor100011">
    <xsd:appinfo source="">
    <xsd:element name="root">
    <xsd:appinfo source="">
    <xsd:element name="head" type="xsd:string">
    <xsd:appinfo source="">
    <xsd:element name="rows" minOccurs="0" maxOccurs="unbounded">
    <xsd:appinfo source="">
    <xsd:element name="value" type="xsd:string">
    <xsd:appinfo source="">
    <xsd:element name="filenode">
    <xsd:appinfo source="">
    <xsd:element name="filename" type="xsd:string">
    <xsd:appinfo source="">
    <xsd:element name="filepath" type="xsd:string">
    <xsd:appinfo source="">
    I've tried to set "Recordset Structure" in file adapter configuration to "root,filenode" and to "Proveedor110001, filenode" but no output is writed
    We are using XI version: SAPKB64015, which version did  you use in your weblog?
    Thanks and regards,

  • Receiver JMS Adapter Content Conversion issue

    Scenario :
    R/3 -->XI -->MQ(XML2Plain)
    We are using Receiver JMS Adapter to send the Message from XI to MQ.
    The XML has to be converted to plain file. And Content conversion is
    being done.
    With the new development, the message type defined consist of 8 fields
    with fixed length. The XML message goes successfully from XI to MQ
    without any content conversion. But once simple content conversion is
    being done for Receiver JMS adapter, even though the message is
    received but it’s empty (without any data records). The adapter
    monitoring everything seems fine and it gives the status that message
    converted to binary and the message is delivered to MQ. Though on
    checking the messages there is no data records.
    Below is my content conversion configuration done in Module tab. Kindly
    revert back what can be the problem as have done exactly the same way
    as described in Content Conversion How to Guide for receiver JMS.
    localejbs/AF_Modules/MessageTransformBean Local Enterprise Bean  XML2Plain
    localejbs/SAP XI JMS Adapter/ConvertMessageToBinary Local Enterprise Bean convert_XI2Bin
    localejbs/SAP XI JMS Adapter/SendBinarytoXIJMSService Local Enterprise Bean exit
    XML2Plain Transform.Class
    XML2Plain TransformContentType text/plain;charset=utf-8
    XML2Plain xml.addHeaderLine 0
    XML2Plain xml.addHeaderLine SimpleXML2Plain
    XML2Plain xml.fieldFixedLengths 8,10,10,20,40,40,8,8
    XML2Plain xml.fixedLengthTooShortHandling Cut

    check localejbs/SAP XI JMS Adapter/ConvertMessageToBinary Local Enterprise Bean convert_XI2Bin
    this is not CallJMSService.
    And also check the receiver Structure, if it is falt structure its ok, else
    see the below link if it has the complex structure , how to handle..
    See the below links
    content conversion

  • Sender File Adapter - Content Conversion

    HI Friends,
    I got a scenario where I need to convert the File to XML document through Sender file adapter..
    My file looks like below.
    So there is a Header and Body for each record set..
    My XML Structure is as follows.
             <Field1>BATCH </Field1>   
             <Field2> ...</Field2>
             <F1> ...... </F1>
             <F2> ...... </F2>
             <Field1> BATCH  </Field1>   
             <Field2> ADFAS  </Field2>
             <F1> ...... </F1>
             <F2> ...... </F2>
    The blog <a href="/people/shabarish.vijayakumar/blog/2006/02/27/content-conversion-the-key-field-problem:///people/shabarish.vijayakumar/blog/2006/02/27/content-conversion-the-key-field-problem
    is somewhat relevant to my requirement.
    But the problem is I have the keyfield "BATCH" for my header file but don't have any <b>key field in the data record</b> of the input file.
    Please help me out how to mention the configuration parameters.

    If you don't have constant key value for your detail records, then you can not directly get the required xml.
    So in this case, you can read all the records in a common Row model, i.e each record will be considered as a one row with all the values, and then split this row with Substring or java functions in the mapping.
    Even you can do this in the Adapter module .
    If you have key value for each record to identify then you can try with content conversion.

  • File adapter content conversion

    Hi all,
      We are having File to File Scenario
      We are facing problem in Content conversion in File
      The source file is in text format and fields are
      seperated by '|' character
      The source file structure is :
      Header|No. of Records
      Data Record1 
      Data Record2
      Data Recordn
      Trailer|No. of Records
         where Data Recordn is of type Field1|Field2|Field3|Field4
         and the number of data records is variable
      Now , we need to ignore the contents of Header and Trailer Records
         For Header , we are setting the property Document Offset to 1
         Hence the Header record is ignored
         However , we are facing problems in ignoring the Trailer record
         We want to know :
         1. Is there a direct way ( or some propety ) wherein we can ignore the last record of the file ,
            which in this case is Trailer record
         2. We also tried the following :
              a. We set the Recordset Structure to : row,*,trailer,1
              b. However in this case , the keyField is required for row ;
                 but since the number of data records is variable ,
                 the keyFieldValue cannot be specified
           How should we go about in this case
    Please guide us on this

    Hi all
    Thanks for replies
    Actually , we are able to ignore header and that is not an issue
    Now if we need to discard the trailer record , we believe that RecordSet Structure should be <b>row,,trailer,1</b> or <b>header,1,row,,trailer,1</b>
    However , since structure is <b>row,*</b> ; we need to specify the <b>keyField</b> column for row ( data records )
    Since <u>number of data records</u> is variable , we are not able to set the <b>keyFieldValue</b> for <u>row ( data record )</u>
    Can you'all please guide us on this as we are stuck on this .
    Message was edited by: Shikha Jain

  • Replace String in csv file with file adapter content conversion

    Hello experts,
    I have a sender file channel to receive csv files from an external server. I can process the csv files but I have a little problem. Since the separator in the csv file is a comma and sometimes a comma also appears in the dates but this time it is not a separator.
    1234,20120123,ABCD,customer, which has a comma in it's name,...
    5678,20120123,FGHI,customer without comma,...
    My plan is to remove all commas when a blank follows.
    My current content conversion looks like this:
    Record.fieldNames field1,field2,...
    Record.fieldSeparator ,
    Record.endSeparator 'nl'
    Is there something like Record.fieldReplaceString or something similar which I can use? Or is there perhaps a better way to do this?
    I'd appreciate every help I can get here.
    Best regards.

    Hi Oliver,
    I think I've got a solution for you, after all. All you need to do is have your customer name enclosed in quotes, like that:
    1234,20120123,ABCD,"customer, which has a comma in it's name",...
    Use the rest of FCC configuration as usually. You might also want to have a look at this wiki entry for a configuration example:
    Moreover, see the description for "NameA.enclosureSign" in the help document below:
    Hope this helps,

  • Receiver JMS adapter content conversion

    Hi All,
    Can anyone provide me guidelines on how to do content conversion for the receiver JMS adapter??

    Based on your structure , you need to configure the JMS CC parameters.
    see the below link

  • Key field from content - Sender file adapter content conversion

    I am reading a source CSV file that has this structure. All rows in the source file are the same structure: line items of a PO. But there will be multiple POs in a single file, identified by the PO number as one column in the file.
    Goal is to generate 3 messages, one for each PO:
              ... 3 line items for PO # 001 ...
              ... 2 line items for PO # 002 ...
              ... 1 line item for PO # 003 ...
    Is there any way to use the Content Conversion Key Field Name to group the line items into the correct 3 messages? "Key Field Name" expects a static identifier for each type of row; but mine varies by the PO number in the content.
    Or do I need to do this in the mapping? If so, what is the easiest way to split 1 large message of all line items into multiple target messages based on the PO number? (I assume this is better than sending individual line item messages and aggregating them later, as long as the file size is OK.)
    Thanks in advance!
    Edited by: Robert Burfoot-Lobo on Apr 8, 2009 11:43 AM

    Hi Robert,
    If ur goal is to split into 3 messages one for each PO, you can go for message split and using graphical mapping you can achieve that.
    Within the message mapping go to the tab Messages.
    Change the occurrence of the target message to 0..unbounded.
    Also this link may help you.

  • File Adapter content conversion delimited/possitional file format.

    I have the following file to JDBC scenario, but having some issues with the file content conversion due to the file structure.
    000038A020101=AA1=AC1=AD=AG1=AH1=AI1=AK3049572=BN01 =BOMETLSS_ML_STD_30A7
    Example 2:
    000040A020101=AA1=AC1=AD=AG1=AH1=AI1=AK3049570=BN01 =BOMETLSS_ML_STD_30A7
    000041A020101=AA1=AC1=AD=AG1=AH1=AI1=AK3049571=BN01 =BOMETLSS_ML_STD_30A7
    000042A020101=AA1=AC1=AD=AG1=AH1=AI1=AK3049572=BN01 =BOMETLSS_ML_STD_30A7
    Example Explained:
    Position 1-9 is a "Transactional number".
    Position 10-11 is "Record type".
    Position 12-13 is "Line Item count".
    Four record types exist:
    03 = Location header
    01 = Transactional Header
    02 = Line Item
    OLRENDZZZZ = EoF marker.
    The equal sign "=" is a field separator/delimiter.
    In each delimited field, after the first equal sign in the record, the first two characters represent a field qualifier/field name tag/identifier and there only the data begins until the following delimiter.
    Each record is ended in a "CLRF"/'nl'.
    The file is build up, but not locked and only completed until the EoF marker "OLRENDZZZZ" is inserted by the application on the last record of the file.
    My solution so far:
    Record Structure: row,*
    Record Sequence: Ascending
    row.fieldNames: field1,field2,field3,ect.......
    row.fieldSeparator: =
    row.endSeparator: 'nl'
    row.keyFieldInStructure: ignore
    ignoreRecordsetName: true
    This brings the file into the integation server as xml as follow:
    <?xml version="1.0" encoding="utf-8"?>
    <ns:SAPtoFuelFACS xmlns:ns="urn:engenoil-com:i_fuel_facs_sap">
    So far, so good.
    The problem I am having is that I have to check for the EoF marker "OLRENDZZZZ" to be present before picking up the file, else the file is not completed.
    I have tried a script to rename files in msg pre-processing in the channel, but the problem is the file channel has to be triggered and the original file mask is necessary for this, but then this mask is a valid pickup file mask. So to me it seems the only way is to do this is during the content conversion process as the files not matching the file criteria, where a EoF "OLRENDZZZZ" definition is not present, will not be picked up and be ignored until it is present or totally independent with a batch job.
    If someone has a more elegant way to solve this problem with just using the file channel configuration where every thing is pretty much apparent, I would greatly appreciate it if you could assist.
    Willie Hugo

    The problem I am having is that I have to check for the EoF marker "OLRENDZZZZ" to be present before picking up the file, else the file is not completed.
    I suggest a script.
    Say The files are dropped in FolderA. Have a script transfer a file to FolderB only if it finds the EoF marker in a file. Thus FolderB will be what XI will poll and that will always have the complete file.
    Hope this sounds good!!!

  • Sender file adapter - content conversion question

    Hi all
    We have a .csv file to be passed to XI that has column headings as well. Is there a way of stripping the header using "Content conversion". We declared the RecordsetStructure as "header,1,item,*" but then it needs a keyFieldname and identifier which is obviously not available as the first line only has column headings.
    Hoping for a reply soon.

    In RecordsetStructure you define as header,1,item,9999999999. But if you have more than 9999999999 records then the extra records after this will come as a second file.
    If you expect more item records then increase the number of 9's. Then we dont need to give the key field.

  • Sender File Adapter-Content conversion for a tab delimited file

    Hi all,
    I have a FIle to IDoc scenario, where the File is with the structure Header,Detail,Trailer.
    Header and Trailer are with fixed field lengths, whereas the detail records are tab delimited.(Functional spec says delimited by H'05').
    I have given the parameters as follows:
    Header.keyFieldValue     H
    Header.fieldFixedLengths     1,1,4,1,8
    Header.fieldNames     a,b,c,d,e
    Header.endSeparator     'nl'
    Detail.fieldNames     a,b,c,d,e,f
    Detail.fieldSeparator     '0h05'
    Detail.keyFieldValue     LOA
    Detail.endSeparator     'nl'
    Trailer.fieldFixedLengths     1,1,8
    Trailer.fieldNames     a,b,c
    Trailer.keyFieldValue     T
    ignoreRecordsetName     true
    In SXMB_MONI, I get the payload with just the Header and Trailer and not the detail records, even though my file has so many records in it.I m pretty sure, this happens because of my Detail.fieldSeparator parameter.
    Can anyone please help me with this?What is the correct value for this parameter?
    Thanks a lot in advance!

    first of all make sure with a hex editor that the hex code of the delimiter sign is really 05. This is an odd character, as the normal tab is hex 09.
    when you have confimred it, check online help for file adapter config for the correct entry of hex codes. I think it is something like '0x05',
    Edited by: Stefan Grube on Feb 10, 2011 6:43 PM

Maybe you are looking for

  • Suggestions on a server setup please...

    Hello all, I'm about to configure a server for a small office but before going ahead I'd love to hear opinions on my proposed setup from the more experienced amongst you and suggestions on anything I should change/add/remove. Here's my current thinki

  • Error while installing ODEQ

    Hi, There is a particular error coming while installing Oracle Data Enterprise Quality 9.0.8 in integration with Oracle Data Integrator(ODI). The error details are as below:- 1st Case:--- Initialising Director Store instance Initialising Director Sto

  • What are the methods called while navigating from one applet to another one

    Hi All, Could any one brief me about "When you navigate from one applet to another what are the methods called ?". Thanks in advance. Best Regards, N.Madhusudhanan.

  • When we go for reint.

    Hi all, In what scenario we go for reint. can somebody describe... Regards Kiran Kumar

  • TXT Files in Design View

    I use a lot of TXT files as INCLUDE files in various pages. When I used Dreamweaver 4 I had no problem editing a TXT file just like any HTML file and using DesignView. When I get going with Dreamweaver MX2004 I figured out how to do it. But I had to