to convert the output of aggregator to integer

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
lakshmipriya
Participant
Posts: 31
Joined: Tue Jul 13, 2004 5:26 am
Location: chennai
Contact:

to convert the output of aggregator to integer

Post by lakshmipriya »

Hi

In am using an aggregator stage to do a sum of a count whose output should have a data type of integer.
But as of my knowledge i am getting the output only in dfloat and decimal. While tryong to to convert it into integer it is showin warning.

How to convert the output from decimal to integer without any warning.
Lakshmi
richdhan
Premium Member
Premium Member
Posts: 364
Joined: Thu Feb 12, 2004 12:24 am

Post by richdhan »

Hi Lakshmi,

The default output of an Aggregator is decimal. What are you doing to convert it to integer. Pls explain.

Is this the warning you are getting?

Code: Select all

Implicit conversion; from source type "int32" to result type "decimal[2,0]": Possible range limitation
I think this warning is OK. Anyway post it on ADN and get the feedback from Ascential people.

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

Post by ray.wurlod »

This is one of those warnings generated by DataStage to let you know that a problem *could* occur.

Your input column is defined as int32 (possible values to 2147483647) while your output is defined as decimal(2,0) (possible values to 99).

Obviously, if anything larger than 99 came in, it could not be output (and may generate an access violation (SIGBUS) abort).
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