A parallel job running into the following...
I have a field in a table defined as follows:
CREATE TABLE diagnosis
(diagnosis_iid NUMBER,
I have a select that is as follows:
(SELECT nvl(MAX(DIAGNOSIS_IID) ,0) LAST_VAL FROM #SCHEMA#.DIAGNOSIS)
The job contains one transformer and the field is mapped to a target field of type integer.
when I run the job, I get the following error/warning:
CONV_LD_DIAGNOSIS: When checking operator: When binding output interface field "LAST_VAL" to field "LAST_VAL": Implicit conversion from source type "decimal[38,10]" to result type "int32": Possible range/precision limitation.
Not sure why....can anyone help explain?
Error in Data conversion
Moderators: chulett, rschirm, roy
Error in Data conversion
HAVE A GOOD ONE
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
It's generated because Oracle does not have a true INTEGER data type, and converted your INTEGER specification in CREATE TABLE to NUMBER(38) or - in your particular case - because the default size of NUMBER is 38. But your job design takes this and tries to import it into an int32 (specified in your metadata).
Import the able definition using Orchestrate's orchdbutil command (via the usual Import menu) and use the data type shown there. Include an explicit conversion function (such as int32_from_decimal in a Modify stage).
Import the able definition using Orchestrate's orchdbutil command (via the usual Import menu) and use the data type shown there. Include an explicit conversion function (such as int32_from_decimal in a Modify stage).
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Another Error I get is this:
CONV_LD_DIAGNOSIS,0: Column LAST_VAL floating point decimal is not fully supported; adjusting the scale.
f I make it an integer, I get a conversion error. If I make it a Decimal I get this error. If I make it a varchar, it will be incorrect in the DB. Is there something simple that I am missing?
CONV_LD_DIAGNOSIS,0: Column LAST_VAL floating point decimal is not fully supported; adjusting the scale.
f I make it an integer, I get a conversion error. If I make it a Decimal I get this error. If I make it a varchar, it will be incorrect in the DB. Is there something simple that I am missing?
HAVE A GOOD ONE
-
- Charter Member
- Posts: 560
- Joined: Wed Jul 13, 2005 5:36 am
- Location: Ohio
WhyIsIt?
In the Database I defined the column as NUMBER. When I imported the table into DataStage, that same field gets created at decimal(38,10). Where is that translation being set, I keep getting errors/warnings on the field. How is it that Datastage 'changes' the type from Number to decimal 38,10.
Is there a setting somewhere that I can change?
Is there a setting somewhere that I can change?
HAVE A GOOD ONE
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
use casting in sql
try CASTING the field as NUMERIC(10) in the query and in the metadata change it to Integer(10). This will help you keep it as Integer and will not convert into Decimal.