Reading COMP-3 fields with Sequential file 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
emblem_user
Premium Member
Premium Member
Posts: 8
Joined: Fri Sep 02, 2011 9:33 am

Reading COMP-3 fields with Sequential file stage

Post by emblem_user »

Hi,

I am reading MF file using Seq File stage and the file does have comp-3 fields. I have 4 regions files that I need to process with same code. For one region job works fine but fails for other with error below:
so was wondering if I can use Seq File Stage to read data in COMP-3 fields or If I am converting anything wrong.

Please let me know.
Thanks.

Error:
APT_CombinedOperatorController,1: APT_Decimal::ErrorBase: From: the source decimal has even precision, but non-zero in the leading nybble, or is too large for the destination decimal..Record sent to reject dataset.
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Did you Search DSXchange? I'm pretty certain this exact question has been answered more than once in the past.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
emblem_user
Premium Member
Premium Member
Posts: 8
Joined: Fri Sep 02, 2011 9:33 am

Post by emblem_user »

I read some posts and did not find what can be the issue for my job.

Below is what I think is causing the issue:
15 I_PCT COMP-3 PIC 9(3)V9(6).
15 I_PCT_C REDEFINES
I_PCT COMP-3 PIC 9(1)V9(8).
15 I_PCT_A REDEFINES
I_PCT_C PIC X(5).

Till now I handled Numeric columns redefined as Char columns and Vice Versa.
Can you tell me how can I use Sequential File stage to read the coumns that are redefined as above? the only reason trying to use Seq stage is its performance is much better than CFF stage.

Thanks in advance.
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

Can you use a server job for this? If so, there are server routines to perform COBOL type conversions which you can use.
Post Reply