Page 1 of 1

Re: Reading Ebcdic file Using CFF - Urgent!!!!!

Posted: Thu Dec 30, 2004 3:22 pm
by ogmios
This is not going to help your current situation but I quit using the CFF stage long time ago. I never could get it to work completely for all possible combinations of packings/low and high values on the mainframe, which seems to be the situation you're in.

What I currently do is to generate ASCII files on the mainframe (outside of DataStage), unpacking all packed fields and stripping low- and high-values. One of our mainframe guys wrote a pretty general routine to do that on the mainframe side.

Ogmios

Posted: Thu Dec 30, 2004 3:26 pm
by ArndW
Hello Ravi,

were you just showing us some examples of the errors or all of the errors you found? The reason I am asking is that it is unlikely to not work for some columns while working in others.

The Cobol type conversions will work - I know because I wrote them (a couple of years back).

Are you pulling the file over as ASCII or EBCDIC; i.e. if you are letting DS convert the files and THEN try to do EBCDIC conversions it will cause the types of errors you are alluding to. How are you getting your source data file to the UNIX server box? If you are using FTP then you must use "BINARY" mode otherwise FTP will do that character set conversion for you.

If your COMP-3 fields are working while X and S9 fields aren't it does sound like you are doing an ASCII conversion prior to working on the fields.

Posted: Thu Dec 30, 2004 5:47 pm
by ravivarma20
Hi Arnd,

Our problem got solved. We aren't interpreted the cobol file structure properly. Our cobol file strucure giving three types of records Ctl,Header and Detail. Each record type having different fields.So it is giving junk data when we view the data in CFF stage. Now we splitt the data in transformer based on record type and stored to three output files. It's working fine now.

Thnax for ur input.

Ravi.


ArndW wrote:Hello Ravi,

were you just showing us some examples of the errors or all of the errors you found? The reason I am asking is that it is unlikely to not work for some columns while working in others.

The Cobol type conversions will work - I know because I wrote them (a couple of years back).

Are you pulling the file over as ASCII or EBCDIC; i.e. if you are letting DS convert the files and THEN try to do EBCDIC conversions it will cause the types of errors you are alluding to. How are you getting your source data file to the UNIX server box? If you are using FTP then you must use "BINARY" mode otherwise FTP will do that character set conversion for you.

If your COMP-3 fields are working while X and S9 fields aren't it does sound like you are doing an ASCII conversion prior to working on the fields.

Posted: Sat Jan 01, 2005 8:03 am
by chucksmith
I have a tool that might help with future problems. It creates a dump of the file which you can compare with you metadata. The tool is Create a hex/ascii dump of an ebcdic cobol file. You will find it on the DataStage Tools page of www.anotheritco.com.

Posted: Sat Jan 01, 2005 11:02 am
by dsrules
Ravi,
How are you getting the file from mainframe? are you using DataStage FTP stage to pull the file ? even I coudnt make CFF work for me. I was pullling the file using FTP stage, the meta data for the file was not aligned properly with the incoming data and I had all sorts of nightmares.
Mack