Rounding to 10 or 17

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
snt_ds
Premium Member
Premium Member
Posts: 280
Joined: Wed Oct 18, 2006 11:53 am
Location: Pune, India

Rounding to 10 or 17

Post by snt_ds »

Hi,

My column definition in Oracle is Number (30,24) as we need accuracy upto 24 decimal places.
Using Upsert method in DS to insert rows but it trunactes beyond 10 if we use Decimal data type and truncates beyond 17 if I use Double.
Checked using a Peek stage and it does the same, that is, DS truncates as mentioned above.
How can I get the accuracy as required upto 24?
dsnovice
Participant
Posts: 38
Joined: Thu Jul 22, 2004 11:56 pm
Location: Mclean, VA
Contact:

Post by dsnovice »

Do not do any operations on the column in Datastage transformer.. cast it as Decimal(30,24) in Oci or your source stage and propgate that value directly to orcale OCI stage.. ensure that the meta data matches. that is target also says its Decimal(30,24) or Numeric(30,24)

Thank you,

a novice
snt_ds
Premium Member
Premium Member
Posts: 280
Joined: Wed Oct 18, 2006 11:53 am
Location: Pune, India

Post by snt_ds »

I am calculating this value in the Stage Varibale as 1/<col val>
e.g <col val> is 3 then I will calc 1/3 and expect to save 0.333333..
24 times.
Will casting still help?
Post Reply