Page 1 of 1

Dynamically reading MF binary files

Posted: Wed Jul 28, 2010 4:01 pm
by arunkumarmm
Is there a way to create a job which reads in any MF binary [EBCDIC] file by providing the copybook dynamically?

The copybook may have COMP/COMP-3 fields or may not be.

I need your valuable suggestions to create a Job/Routine [PX Or Server] if at all this is possible.

Posted: Wed Jul 28, 2010 4:55 pm
by vmcburney
Importing the copybook manually is the only way to get a complex flat file definition into DataStage. You need to import the copybook definition and then fill in values for record type and define how you are going to flatten the data. Sometimes you need to modify and tweak the copybook to get DataStage to understand it.

Posted: Thu Jul 29, 2010 3:01 am
by ArndW
To add to Vince's post - once you have those COBOL copybook definitions loaded into DataStage you can write a job which decides at runtime which (previously loaded) schema file is used to read the input data. This job would need to use runtime column propagation to process data, but it is a possible approach to dynamically read complex files.

Posted: Thu Jul 29, 2010 2:30 pm
by arunkumarmm
Thank you guys for the reply. I'm not able to read it fully though. But I will try with the schema file and let you all know.