Floating issue

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
nani0907
Participant
Posts: 155
Joined: Wed Apr 18, 2007 10:30 am

Floating issue

Post by nani0907 »

Hi all

i am getting the below error from the oracle query used.

floating point decimal is not fully supported; adjusting the scale.

Ora query used.
SELECT
DECODE(FN.column A,NULL,'NULL',FN.column A) AS column A,
SUM(CAST(FN.column B AS DECIMAL(38,10))) AS column B
FROM
Table FN
WHERE
FN.DATE=to_date(20071231,'yyyymmdd')
GROUP BY
column A

In oraclestage,mentioned column as decimal 38,10.

Please help me for the above issue.

Aslo unable to view premium content.
thanks n regards
nani
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Re: Floating issue

Post by chulett »

nani0907 wrote:Also unable to view premium content.
I really don't understand why people feel the need to mention this. It is obvious who is a Premium member and who isn't, that's clearly marked on every post. All this statement says is you don't want any of the Premium posters to help you. So be it.
-craig

"You can never have too many knives" -- Logan Nine Fingers
nani0907
Participant
Posts: 155
Joined: Wed Apr 18, 2007 10:30 am

Post by nani0907 »

I donot mean that.
sorry for mentioning it.
thanks n regards
nani
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

What is the definition of "Column B" in the Oracle table? Why do you feel the need to CAST the column during the select?
-craig

"You can never have too many knives" -- Logan Nine Fingers
nani0907
Participant
Posts: 155
Joined: Wed Apr 18, 2007 10:30 am

Post by nani0907 »

Hi,


The column B is mentioned as Number datatype in oracle table without length.
thanks n regards
nani
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Figured as much. What about the second question?
-craig

"You can never have too many knives" -- Logan Nine Fingers
nani0907
Participant
Posts: 155
Joined: Wed Apr 18, 2007 10:30 am

Post by nani0907 »

I have imported the meta data from the Orch schema definitions which shows as decimal 38, 10 . hence used the cast function to do the same.
thanks n regards
nani
Mike
Premium Member
Premium Member
Posts: 1021
Joined: Sun Mar 03, 2002 6:01 pm
Location: Tampa, FL

Post by Mike »

Not sure if it will matter, but...

How about CASTing the SUM instead of SUMing the CAST?

Mike
nani0907
Participant
Posts: 155
Joined: Wed Apr 18, 2007 10:30 am

Post by nani0907 »

I have casted the sum and the issue is resoved.

Thanks mike
thanks n regards
nani
Post Reply