cancel
Showing results for 
Search instead for 
Did you mean: 

FCC Query

Former Member
0 Kudos

Hi,

How do we converththe position based file into XML Format?

I am not sure if the Position Based File is the correct Term but the file is something like ::

Position 0 to 7 : Material

Position 8 to 9 : Sector

Position 10 to 13 : Material Type

Position 14 to 30 : Description

Position 31 to 33 : UOM

etc

etc

eg:

TESTMAT1MROHTEST MAT NOS

YOur valuable input would be helpful and rewarded.

Thanks

Accepted Solutions (0)

Answers (5)

Answers (5)

Former Member
0 Kudos

HI

Refer the below links for assistance on File Content Conversion

File Content prameters for the Receiver Adapter

http://help.sap.com/saphelp_nw04/helpdata/en/d2/bab440c97f3716e10000000a155106/frameset.htm

File Content prameters for the Sender Adapter

http://help.sap.com/saphelp_nw04/helpdata/en/2c/181077dd7d6b4ea6a8029b20bf7e55/content.htm

Refer

File Receiver with Content Conversion

/people/arpit.seth/blog/2005/06/02/file-receiver-with-content-conversion

Configuring the Receiver File/FTP Adapter

http://help.sap.com/saphelp_nw04/helpdata/en/95/bb623c6369f454e10000000a114084/frameset.htm

File content conversion sites

http://help.sap.com/saphelp_nw04/helpdata/en/d2/bab440c97f3716e10000000a155106/content.htm

Please see the below links for file content conversion..

/people/michal.krawczyk2/blog/2004/12/15/how-to-send-a-flat-file-with-fixed-lengths-to-xi-30-using-a-central-file-adapter - FCC

/people/michal.krawczyk2/blog/2004/12/15/how-to-send-a-flat-file-with-fixed-lengths-to-xi-30-using-a-central-file-adapter - FCC

File Content Conversion for Unequal Number of Columns

/people/jeyakumar.muthu2/blog/2005/11/29/file-content-conversion-for-unequal-number-of-columns - FCC

Content Conversion (Pattern/Random content in input file)

/people/anish.abraham2/blog/2005/06/08/content-conversion-patternrandom-content-in-input-file - FCC

/people/harrison.holland5/blog/2006/12/20/xi-configuration-for-mdm-integration--sample-scenario - FCC - MDM

XI in the role of a FTP

/people/shabarish.vijayakumar/blog/2006/04/03/xi-in-the-role-of-a-ftp - FCC

File to R/3 via ABAP Proxy

/people/prateek.shah/blog/2005/06/14/file-to-r3-via-abap-proxy - FCC

/people/mickael.huchet/blog/2006/09/18/xipi-how-to-exclude-files-in-a-sender-file-adapter - EOIO - File

http://help.sap.com/saphelp_nw04/helpdata/en/ee/c9f0b4925af54cb17c454788d8e466/frameset.htm - cc

http://help.sap.com/saphelp_erp2005vp/helpdata/en/95/bb623c6369f454e10000000a114084/content.htm - fcc cOUNTER

https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/da1e7c16-0c01-0010-278a-eaed5eae... - conversion agent

File Content prameters for the Receiver Adapter

http://help.sap.com/saphelp_nw04/helpdata/en/d2/bab440c97f3716e10000000a155106/frameset.htm

File Content prameters for the Sender Adapter

http://help.sap.com/saphelp_nw04/helpdata/en/2c/181077dd7d6b4ea6a8029b20bf7e55/content.htm

Refer

File Receiver with Content Conversion

/people/arpit.seth/blog/2005/06/02/file-receiver-with-content-conversion

Configuring the Receiver File/FTP Adapter

http://help.sap.com/saphelp_nw04/helpdata/en/95/bb623c6369f454e10000000a114084/frameset.htm

File content conversion sites

/people/venkat.donela/blog/2005/03/02/introduction-to-simplefile-xi-filescenario-and-complete-walk-through-for-starterspart1

/people/venkat.donela/blog/2005/03/03/introduction-to-simple-file-xi-filescenario-and-complete-walk-through-for-starterspart2

/people/arpit.seth/blog/2005/06/02/file-receiver-with-content-conversion

/people/anish.abraham2/blog/2005/06/08/content-conversion-patternrandom-content-in-input-file

/people/shabarish.vijayakumar/blog/2005/08/17/nab-the-tab-file-adapter

/people/venkat.donela/blog/2005/03/02/introduction-to-simplefile-xi-filescenario-and-complete-walk-through-for-starterspart1

/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/anish.abraham2/blog/2005/06/08/content-conversion-patternrandom-content-in-input-file

/people/shabarish.vijayakumar/blog/2005/08/17/nab-the-tab-file-adapter

/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

/people/michal.krawczyk2/blog/2004/12/15/how-to-send-a-flat-file-with-fixed-lengths-to-xi-30-using-a-central-file-adapter

/people/arpit.seth/blog/2005/06/02/file-receiver-with-content-conversion

http://help.sap.com/saphelp_nw04/helpdata/en/d2/bab440c97f3716e10000000a155106/content.htm

Please see the below links for file content conversion..

/people/michal.krawczyk2/blog/2004/12/15/how-to-send-a-flat-file-with-fixed-lengths-to-xi-30-using-a-central-file-adapter - FCC

/people/michal.krawczyk2/blog/2004/12/15/how-to-send-a-flat-file-with-fixed-lengths-to-xi-30-using-a-central-file-adapter - FCC

File Content Conversion for Unequal Number of Columns

/people/jeyakumar.muthu2/blog/2005/11/29/file-content-conversion-for-unequal-number-of-columns - FCC

Content Conversion (Pattern/Random content in input file)

/people/anish.abraham2/blog/2005/06/08/content-conversion-patternrandom-content-in-input-file - FCC

/people/harrison.holland5/blog/2006/12/20/xi-configuration-for-mdm-integration--sample-scenario - FCC - MDM

XI in the role of a FTP

/people/shabarish.vijayakumar/blog/2006/04/03/xi-in-the-role-of-a-ftp - FCC

File to R/3 via ABAP Proxy

/people/prateek.shah/blog/2005/06/14/file-to-r3-via-abap-proxy - FCC

/people/mickael.huchet/blog/2006/09/18/xipi-how-to-exclude-files-in-a-sender-file-adapter - EOIO - File

http://help.sap.com/saphelp_nw04/helpdata/en/ee/c9f0b4925af54cb17c454788d8e466/frameset.htm - cc

http://help.sap.com/saphelp_erp2005vp/helpdata/en/95/bb623c6369f454e10000000a114084/content.htm - fcc cOUNTER

https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/da1e7c16-0c01-0010-278a-eaed5eae... - conversion agent

cheers

Former Member
0 Kudos

Hi,

Check this following FCC Guidelines:

/people/shabarish.vijayakumar/blog/2007/08/03/file-adapter-receiver--are-we-really-sure-about-the-concepts

http://help.sap.com/saphelp_nw70/helpdata/EN/ae/d03341771b4c0de10000000a1550b0/frameset.htm

Thanks,

Boopathi

former_member859847
Active Contributor
0 Kudos

Hi,

If your positions are fixed, then plan FCC with fieldFixed Lengths.

item.fieldFixed Lengths :7,2,4,16,3

item.fieldNames : Material,Sector,Material Type,Description

,UOM

warm regards

mahesh.

Former Member
0 Kudos

Hi,

Thanks for the reply.

As suggested, I did the settings as follwos:

Rows.fieldFixedLength = 10,1,3,3,18,2

Rows.fieldNames = Material,IndSec,Mtype,UOM,Desc,Language

The XML file is getting generated but its containing all the fields in single row.

The full row is considered as the material number.

Any idea??

Former Member
0 Kudos

specify Rows.endSeparator = 'nl' .. this will put each record on new line

Former Member
0 Kudos

Thanks but My XML is getting generated as below:

=======

<?xml version="1.0" encoding="utf-8" ?>

- <ns:SCD_MT xmlns:ns="NS:F2BAPI">

- <Records>

- <Rows>

<Material>Mat223 MROHCMTesting EN</Material>

</Rows>

</Records>

</ns:SCD_MT>

=======

I want it as stated below:

=======

<?xml version="1.0" encoding="utf-8" ?>

- <ns:SCD_MT xmlns:ns="NS:F2BAPI">

<Records>

- <Rows>

<Material>Mat2231</Material>

<IndSec>M</IndSec>

<Mtype>ROH</Mtype>

<UOM>CM</UOM>

<Desc>Testing</Desc>

<Language>EN</Language>

</Rows>

</Records>

</ns:SCD_MT>

=======

Edited by: Pranu Pranu on Jun 30, 2008 1:36 PM

former_member859847
Active Contributor
0 Kudos

Hi

use the following FCC parameters.

Records.endSeparator = 'nl'

Rows.fieldFixedLength = 10,1,3,3,18,2

Rows.fieldNames = Material,IndSec,Mtype,UOM,Desc,Language

Rows.endSeparator = 'nl'.

warm regeards

mahesh.

Former Member
0 Kudos

Hope you are specifying

Recordset Name - Records and thus not adding ignoreRecordsetName = true in your parameters

Also as this is fieldFixedLangth conversion, it will expect each field length as per specification... that means 1st 10 char in your file would go as field Material and so on...

so check your input txt file if it contains field values pertaining their length

Rows.endSeparator = 'nl' will take next Row as next record

Former Member
0 Kudos

Hello Pranu,

Try This in same sequence:

Recordset Name : Records

Recordset Structure: Rows,*

Rows.fieldFixedLengths: 10,1,3,3,18,2

Rows.endSeperator: 'nl'

Rows.fieldNames: Material,IndSec,Mtype,UOM,Desc,Language

I hope u hv given correct field lengths & field names.

Field names should match with ur DT/MT exactly.

Thanks,

Mahi

GabrielSagaya
Active Contributor
0 Kudos

You told that

Position 0 to 7 : Material -> 7 char for material

Position 8 to 9 : Sector -> 2 char for sector

Position 10 to 13 : Material Type->3 char for mattype

Position 14 to 30 : Description->16 char for desc

Position 31 to 33 : UOM->2 char for uom

Position 34 to 35: Lang-> 2 char for lang

since your input is like

Mat2231 MROHCMTesting EN

Document Name=SCD_MT

Document Namespace=your namespace

Recordset name=Records

Recordset structure =Rows,*

Additional parameters

Rows.fieldNames=Material,IndSec,Mtype,UOM,Desc,Language

Rows.fieldFixedLengths=7,2,3,2,16,2

Rows.processFieldNames=fromConfiguration

Also note that identify the total no of characters allotted particularly for each field

and assign it to Rows.fieldFixedLengths

No FieldSeparator should be used

/people/michal.krawczyk2/blog/2004/12/15/how-to-send-a-flat-file-with-fixed-lengths-to-xi-30-using-a-central-file-adapter

former_member194786
Active Contributor
0 Kudos

Hi Pranu,

You need to use the fixedFieldLength parameter in the File Content Conversion. It will solve your problem. Refer to the following link for details on how to use it:

http://help.sap.com/saphelp_nw04/helpdata/en/2c/181077dd7d6b4ea6a8029b20bf7e55/frameset.htm

Regards,

Sanjeev.

Former Member
0 Kudos

Hi,

This is a fixed length file.U can read this file by doing FCC on sender adapter.

check the parameters on this URL

http://help.sap.com/saphelp_nw70/helpdata/EN/ae/d03341771b4c0de10000000a1550b0/frameset.htm

depending upon your source File structure.

Please revert if there any doubts with complete source file structure.

Regards,

Anoop