Warnings for decimal fields

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

bi_fujitsu
Premium Member
Premium Member
Posts: 46
Joined: Tue Mar 20, 2007 3:30 am
Location: India

Warnings for decimal fields

Post by bi_fujitsu »

Hi All,

I am getting warnings for all the decimal fields in my job.

ORA_DISTRIBUTOR: Column OID floating point decimal is not fully supported; adjusting the scale.

I am extracting data from Oracle table(ORA_DISTRIBUTOR). Datatype and length of the OID column in Oracle table is Numeric 38 but in metadata it is showing Decimal 38 and scale 10....

How to remove this warning please suggest me...

Thanks in Advance
DSguru2B
Charter Member
Charter Member
Posts: 6854
Joined: Wed Feb 09, 2005 3:44 pm
Location: Houston, TX

Post by DSguru2B »

Import the metadata with orchbutil. That is more accurate. Before that, change the scale to 0 and see if that helps.
Creativity is allowing yourself to make mistakes. Art is knowing which ones to keep.
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Stop using unbounded NUMBER data types in Oracle.

What I mean here is that, if you create a column whose data type is an unqualified NUMBER in Oracle, a query for the metadata (using DESCRIBE, DataStage or any other tool) will report this as NUMBER(38).

If you create a column in Oracle with data type INTEGER (which does not exist in Oracle), a query for the metadata will report this as NUMBER(38) also.

The solution is to be very specific with the Oracle CREATE TABLE statement to create NUMBER(10) - for example - rather than just NUMBER, whether explicit or implied.
Last edited by ray.wurlod on Thu Apr 05, 2007 1:17 pm, edited 1 time in total.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
bi_fujitsu
Premium Member
Premium Member
Posts: 46
Joined: Tue Mar 20, 2007 3:30 am
Location: India

Post by bi_fujitsu »

DSGuru,

I have changed the value of scale to 0 but it's giving the same warning.

Ray:- Can you please elaborate it, I didn't get you?


Thanks
DSguru2B
Charter Member
Charter Member
Posts: 6854
Joined: Wed Feb 09, 2005 3:44 pm
Location: Houston, TX

Post by DSguru2B »

What is x and y supposed to be in Decimal(x,y) ???
Creativity is allowing yourself to make mistakes. Art is knowing which ones to keep.
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Precision and Scale. :wink:
-craig

"You can never have too many knives" -- Logan Nine Fingers
DSguru2B
Charter Member
Charter Member
Posts: 6854
Joined: Wed Feb 09, 2005 3:44 pm
Location: Houston, TX

Post by DSguru2B »

chulett wrote:Precision and Scale. :wink:
Hehe. I meant actually the value that is supposed to be.
Is it really (38,10) ? How do you know the scale is 10 ?
Creativity is allowing yourself to make mistakes. Art is knowing which ones to keep.
dskid
Participant
Posts: 13
Joined: Mon Jun 19, 2006 12:23 am
Location: uk

Is this is bug in Datastage

Post by dskid »

I too face the same problem alonge with this i am getting one more warning :( I am finding the count using the query in oracle stage and what should i give the data type for the count?
*Implicit conversion from source type "dfloat" to result type "int32": Possible range/precision limitation.*
*Implicit conversion from source type "decimal[38,10]" to result type "int32": Possible range/precision limitation.*
I am getting the above warnings.
Is this a harmful warning? Or can we simply ignore them or handel them?
It will be very helpful for every one - if some one tells what the data type to be defined when deriving value using query like Count Or Sum Or Max Or Level using oracle stage.
Is this is bug in Datastage - when ever i try to import metadata from oracle tables it will import all integer related columns as decimal.
us1aslam1us
Charter Member
Charter Member
Posts: 822
Joined: Sat Sep 17, 2005 5:25 pm
Location: USA

Post by us1aslam1us »

Dskid, I don't think your issue is same as the OP.

You are getting those warnings as you are trying to pass a dfloat field to int32. It is informing you about it. This can be avoided by using Modify Stage after you aggregator to convert double to integer or just create a message handler to make this warning informational.
I haven't failed, I've found 10,000 ways that don't work.
Thomas Alva Edison(1847-1931)
dskid
Participant
Posts: 13
Joined: Mon Jun 19, 2006 12:23 am
Location: uk

Post by dskid »

Thanks us1aslam1us for immediate reply,
Is there any way i can avoid these warnings rather than handling after they were generated?
:shock:
us1aslam1us
Charter Member
Charter Member
Posts: 822
Joined: Sat Sep 17, 2005 5:25 pm
Location: USA

Post by us1aslam1us »

As i said earlier use modify stage for doing an explicit conversion before sending them to target.

IHTH
I haven't failed, I've found 10,000 ways that don't work.
Thomas Alva Edison(1847-1931)
ravibabu
Participant
Posts: 39
Joined: Tue Feb 13, 2007 12:18 am
Location: vijayawada

Post by ravibabu »

Hi,


Set the datatype has bigint in datastage.


Ravi Babu.
jreddy
Premium Member
Premium Member
Posts: 202
Joined: Tue Feb 03, 2004 5:09 pm

Post by jreddy »

setting the datatype as BigInt didnt get rid of the warnings..
Has anyone been able to get rid of these warnings? pls advise
Minhajuddin
Participant
Posts: 467
Joined: Tue Mar 20, 2007 6:36 am
Location: Chennai
Contact:

Post by Minhajuddin »

In the select query you can try this


select To_Char(col) from .........


And in the table definition in Datastage you can give it as a VARCHAR.

It always works for me :)
Minhajuddin

<a href="http://feeds.feedburner.com/~r/MyExperi ... ~6/2"><img src="http://feeds.feedburner.com/MyExperienc ... lrow.3.gif" alt="My experiences with this DLROW" border="0"></a>
Ultramundane
Participant
Posts: 407
Joined: Mon Jun 27, 2005 8:54 am
Location: Walker, Michigan
Contact:

Post by Ultramundane »

jreddy wrote:setting the datatype as BigInt didnt get rid of the warnings..
Has anyone been able to get rid of these warnings? pls advise
Yes. And, that error is a big deal. I had IBM fix many corruption issues with decimals. There are several patches which can be installed to fix the issues. It is shame that IBM doesn't know how to inform customers of critical bugs in their products.
Post Reply