Skip to Content
avatar image
Former Member

FCC for fixed length delimited file

Hello experts,

I have to pick up a .txt file from source directory that is basically a fixed length delimited file,',' being the delimiter.SAP help says:

NameA.fieldSeparator

■ If you made an entry for fieldFixedLengths, the extra length of the separator is taken into account, but no further consistency checks are performed.

This at least suggests that the fixed length delimited file can be converted to XML in file adapter by specifying both fieldSeparator and fieldFixedLengths parameters. Has anyone tried this ?

Thanks,

Monika

Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

3 Answers

  • Best Answer
    Sep 26, 2012 at 03:18 PM

    use field separator or Fixed lenght, dont try to use both and it is not recommended and you will face many issues if there is no value in flat file.

    my suggestion is use field separator to convery yur text document to xml using File adapter FCC.

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Sep 26, 2012 at 04:14 PM

    Thanks Raja and Sagarika for your replies.

    My file will look like below:

    ABC ,123, ,DEF

    GHI ,456, ,JKL

    So, to pick up this file, should I go for fieldSeparator = ','.

    Regards,

    Monika

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Amit Srivastava

      Thanks Amit!! SAP documentation says so that we can use both the parameters, first will try using only field.Separator and see the behavior in case of leading/trailing spaces or spaces when fields are missing, if this works (should work since field length will be ignored), then good, else will try using both the parameters.

      Regards,

      Monika

  • avatar image
    Former Member
    Sep 26, 2012 at 03:23 PM

    Hi Monica,

    I think you Can't use both the parameters, 'fieldSeparator' & 'fieldFixedLengths'.

    If you are using 'fieldFixedLengths' then you can use 'endSeparator' inplace of 'fieldSeparator'.

    Please find the thread http://scn.sap.com/message/8495404 which may be helpful for you.

    Best Regards,

    Sagarika

    Add comment
    10|10000 characters needed characters exceeded