Decimal

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
manikumar
Participant
Posts: 4
Joined: Sat Jul 03, 2010 8:30 am
Location: mail
Contact:

Decimal

Post by manikumar »

Hi,

i have an input seq file
i have input like this

column1
----------
2.49558695
6.766
9.18347580
3.495
2.494020

the column datatype is decimal

the out put like this
column1
--------
.495
.766
.183
.495
.494
Sreenivasulu
Premium Member
Premium Member
Posts: 892
Joined: Thu Oct 16, 2003 5:18 am

Post by Sreenivasulu »

Conver to 'varchar' and use field+Right function to get 3 digits after the decimal position

Regards
Sreeni
Sainath.Srinivasan
Participant
Posts: 3337
Joined: Mon Jan 17, 2005 4:49 am
Location: United Kingdom

Post by Sainath.Srinivasan »

Try something like

Code: Select all

yourField - Int(yourField)
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

DecimalToDecimal() where the target has a scale of 3 ?
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