cancel
Showing results for 
Search instead for 
Did you mean: 

File Content Conversion - No Key Field in Detail Structure

vijay_ravindran
Explorer
0 Kudos

Hi,

     Background - We are receiving a Flat File from an external system which contains Header, Detail and Trailer records. Detail Records are fixed length comma separated. See Sample data below -

HDRXXXYYY12345

MM8100422373,M631530008  ,1530008,031615,17 

MN8100424411,M631530008  ,1530008,031615,22 

XY8100422373,M631530008  ,1530008,031615,17 

TRLXXZZZ4321

First line is the header (HDR - identifier) and the last line is trailer (TRL - identifier). As you can see there is no identifier for Detail records.

And so, it is throwing an error in the File Content Conversion of this file. Is there any way to implement the logic that if identifier is not equal to 'HDR' or 'TRL', it should be detail record?

Does anyone have idea on how to segregate the data into Header, Details and Trailer records? Is there any way to achieve this using java coding before message processing?

Thanks.

View Entire Topic
Former Member
0 Kudos

Hi Vijay,

It is possible through Graphical mapping itself take the whole file records as string and maintain mapping as per your requirement please find the attached images to achieve this. Use logic based on Fixed length of your fields use substring.

Regards,

Suhale Shaik.

former_member355445
Participant
0 Kudos

This message was moderated.