Issue while handling Decimal Fields in CFF Stage

Post questions here relative to DataStage Enterprise/PX Edition for such areas as Parallel job design, Parallel datasets, BuildOps, Wrappers, etc.

Moderators: chulett, rschirm, roy

Post Reply
DSFreddie
Participant
Posts: 130
Joined: Wed Nov 25, 2009 2:16 pm

Issue while handling Decimal Fields in CFF Stage

Post by DSFreddie »

Hi All,

I have a CFF stage as Target for my DataStage Parallel Job.
We create this file, transmit it to MF system to do a comparison.

However, when the files are NDM'd to the Source MF system, the '.' symbol of the decimal values are getting truncated due to which the comparison fails.

For e.g: a decimal field 100.01 when it goes to MF system changes to 10001.

We are using Generic UNIX script to NDM the files from UNIX system to MF system.

Any help will be appreciated.

Thanks,
Freddie
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Could it be that the mainframe expects "masked decimals" in which the metadata (for example PIC 9999V99) tells it where the decimal placeholder needs to be?
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
DSFreddie
Participant
Posts: 130
Joined: Wed Nov 25, 2009 2:16 pm

Post by DSFreddie »

Hi Ray,

Thanks for your response.

To answer your point, mainframe is not expecting "masked decimals".

Let me put it this way,

We have a field A with datatype PIC -9(15).99.While it goes to MF system, the '.' gets truncated.

We have defined this field as CHAR(19). Is there anyother way we can define this field ?
I am trying the various options in the column metadata like Sign Indicator/Sign Option etc.

Any guidance will be much appreciated.

Thanks,
Freddie
FranklinE
Premium Member
Premium Member
Posts: 739
Joined: Tue Nov 25, 2008 2:19 pm
Location: Malvern, PA

Post by FranklinE »

Freddie,

What is the table definition for your "Field A" in each stage up to and including CFF? Is it numeric, decimal or something else?

In general, a PIC 9() field is decimal in DataStage, and if you want to move it as a display field you might be missing a DecimalToString() transform. That might make the decimal point character disappear.

I might be asking the wrong question, but it's the only one that comes to mind. :)
Franklin Evans
"Shared pain is lessened, shared joy increased. Thus do we refute entropy." -- Spider Robinson

Using mainframe data FAQ: viewtopic.php?t=143596 Using CFF FAQ: viewtopic.php?t=157872
ds_teg
Premium Member
Premium Member
Posts: 51
Joined: Tue Aug 11, 2009 6:53 am
Location: Chicago

Post by ds_teg »

if you have the copy books ..import those table definitions and see if you have given it correctly in CFF
Post Reply