can a field be defined Decimal(2,2) in the database?

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
smohd1338
Premium Member
Premium Member
Posts: 28
Joined: Fri Aug 03, 2012 1:09 pm

can a field be defined Decimal(2,2) in the database?

Post by smohd1338 »

Hi,

I have this wierd requirement, i dont know if the table was designed wrong, but my process is aborting due to this reason.

I have field as Integer(2), from flat file and that is staraight drop in to table into a filed which defined as decimal(2,2), in transformer i directly gave as decimal(2,2) and is failing with many of these warnings

the source decimal has even precision, but non-zero in the leading nybble, or is too large for the destination decimal..Record dropped.


on investigating i discovered its decimal(2,2) and i changed it ti decimal(4,2) and ran target as dataset, its working . So can there be decimal(2,2) or should i ask my DBA to change it to (4,2)
sameer
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Decimal(2,2) is not possible. Precision must be at least one greater than scale. So, yes, request the DBA to make the change.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
smohd1338
Premium Member
Premium Member
Posts: 28
Joined: Fri Aug 03, 2012 1:09 pm

Post by smohd1338 »

Thanks a lot ray
sameer
Post Reply