cancel
Showing results for 
Search instead for 
Did you mean: 

File Content Conversion issue

Former Member
0 Kudos

Hi ,

I am working on file content converion for one of the text fixed lenght file to converted to XML data to process in XI.

I have the file structure as

A1071176100317435988049B0D151

A2P 90207645 0000100000E 000715071176

or like this

A1071176100317435988049B0D151

A2P 90207645 0000100000E 000715071176

A2P 90207645 0000100000E 000715071176

A2P 90207645 0000100000E 000715071176

A1071176100317435988049B0D151

A2P 90207645 0000100000E 000715071176

A2P 90207645 0000100000E 000715071176

A2P 90207645 0000100000E 000715071176

First file getting processed successfully but the second file is failing in file content conversion.

I have the configurtion like this

RecordSet Structure Header,1,Item,*

Key Field Name Record_Type

Header.fieldFixedLengths 2,6,6,6

Header.fieldNames XXX,YYY,ZZZ,AAA

Header.keyFieldValue A1

Header.endSeparator 'nl'

Item.fieldFixedLengths 2,1,1,2

Item.fieldNames XXX,YYY,ZZZ,AAA

Item.keyFieldValue A2

Header.missingLastFields ignore

Item.missingLastFields ignore

i jsut want to know why my second file is not getting executed . Is it because i have given RecordSet Structure as Header,1,Item,*

will it work if i give RecordSet Structure Header,,Item,

Thanks

Lakshmi S

Accepted Solutions (0)

Answers (4)

Answers (4)

Former Member
0 Kudos

Hi,

I am having same type of structure and it is working fine. But I have added few more parameters like Line.endSeparator='nl' & Line.lastFieldOptional='YES" & Header.lastFieldsOptional='YES".

Reg,

NJ

Former Member
0 Kudos

Hi,

For ur configuration in FCC..if u give this file as input... it will fail..

A1071176100317435988049B0D151

A2P 90207645 0000100000E 000715071176

A2P 90207645 0000100000E 000715071176

A2P 90207645 0000100000E 000715071176

A1071176100317435988049B0D151

A2P 90207645 0000100000E 000715071176

A2P 90207645 0000100000E 000715071176

A2P 90207645 0000100000E 000715071176

Because the occurence of herder u have given is 1 but its having more than 1 header....

Also if u give header,,item, also it wil nt work bcoz... u r saying here that header first and then items..(sequence matters)

So the best way u can do if the source file is as above is...

Access them as a single record.... all the records are accessed as a single record and then in mapping u can separate them..

by checking if they startsWith A1 or A2...

So ur FCC will be now...

RecordSet Structure Records,*

Records.fieldNames Data

Records.fieldSeparator 'nl'

Babu

stefan_grube
Active Contributor
0 Kudos

> For ur configuration in FCC..if u give this file as input... it will fail..

I have just the same configuration and it works well in PI 7.1

What exactly is the error message in adapter channel monitor?

You can try also:

RecordSet Structure Header,*,Item,*

Former Member
0 Kudos

Dear Stefan,

I request u to read the post once more....

In the previous posts the RecordSet structure is given as

RecordSet Structure Header,1,Item,*

ad not as,

RecordSet Structure Header,,Item,

And s u r correct this structure will also work...

Babu

stefan_grube
Active Contributor
0 Kudos

> i jsut want to know why my second file is not getting executed . Is it because i have given RecordSet Structure as Header,1,Item,*

That is OK. Put Record Sequence to "Ascending", so it should work.

Former Member
0 Kudos

I have already given record sequence as Ascending but still not worki ng .

Former Member
0 Kudos

hi,

you have defined record set as -Header,1,item,*

but in your second file the header is occurring more than once..thats why it is failing

change the header occurrence and it will work.

if u are expecting the header to more than once than define it as *.

thanks

Navneet