Aggregator O/p Data on summation

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
dhletl
Participant
Posts: 22
Joined: Mon Aug 23, 2004 1:13 am

Aggregator O/p Data on summation

Post by dhletl »

Hi,

In the aggregator stage, is there an option that the o/p of summation of a decimal field is produced in the desired decimal format - without any leading / trailing zeroes.

From example -(i/p and o/p from aggregator based on a key)

I/P --fld1 values--100,200, 300
O/P--Sum(fld)1---600.0 [and NOT 000006000.00 for dataype decimal(11,2) ]

I understand it can be handled later in downstream using a transformer stage. I am looking for a direct solution - possibly in the aggregator stage itself.

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

Post by ray.wurlod »

No.

(Can't get more direct than that.)
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
dhletl
Participant
Posts: 22
Joined: Mon Aug 23, 2004 1:13 am

Post by dhletl »

Thanks Ray..

Then...What is your suggestion on the simplest way to convert a field of data type double to a data type decimal of specific precision say decimal(22,2)

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

Post by ray.wurlod »

A following Transformer stage would seem to be the easiest. And/or a build op if you're into coding of these beasts. The build op gives you greater flexibility in handling out of range values (precision 22 may not handle all Double numbers).
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Post Reply