Un-handled conversion error in a join stage

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
DStage_Developer
Participant
Posts: 15
Joined: Fri Mar 09, 2007 8:22 am

Un-handled conversion error in a join stage

Post by DStage_Developer »

Hi all.

I have a question. I'm using a join stage and I get the error below when running the job. The join key is defined differently in the tables themselves. i.e. the join key in table a is defined as an integer 10 while in table b it is a small int 5. Any assistance is greatly appreciated!

Join_364,1: Un-handled conversion error on field "PRD_GRP_ID " from source type "int32" to destination type "int16":
source value="32877"; the result is non-nullable and there is no handle_null to specify a default value.
sud
Premium Member
Premium Member
Posts: 366
Joined: Fri Dec 02, 2005 5:00 am
Location: Here I Am

Re: Un-handled conversion error in a join stage

Post by sud »

Well the error statement is self explanatory. The table where you have small int, you should put as integer, datastage is actually converting both to smallint and doing the comparision and failing since your table a has bigger numbers coming in. Also, handle the nullability. For this you can place a condition which says that the lookup should be done only for non-null values.
It took me fifteen years to discover I had no talent for ETL, but I couldn't give it up because by that time I was too famous.
DStage_Developer
Participant
Posts: 15
Joined: Fri Mar 09, 2007 8:22 am

Re: Un-handled conversion error in a join stage

Post by DStage_Developer »

I've tried to change the data type in the join stage. That didn't work. I received the same error. Also, where can I modify the lookup condtion on the join. I'm very new with Dstage. Any help is greatly appreciated!
sud
Premium Member
Premium Member
Posts: 366
Joined: Fri Dec 02, 2005 5:00 am
Location: Here I Am

Re: Un-handled conversion error in a join stage

Post by sud »

DStage_Developer wrote:I've tried to change the data type in the join stage. That didn't work. I received the same error. Also, where can I modify the lookup condtion on the join. I'm very new with Dstage. Any help is greatly appreciated!
Inside the lookup stage if you look at the left side where it shows the input links, the reference link box will have a place called "Condition". Double click there and you will be able to specify condition.

But I think the problem is because of the datatypes ... please change the datatype of both the input link key columns to integer instead of small int. It should work.
It took me fifteen years to discover I had no talent for ETL, but I couldn't give it up because by that time I was too famous.
DStage_Developer
Participant
Posts: 15
Joined: Fri Mar 09, 2007 8:22 am

Re: Un-handled conversion error in a join stage

Post by DStage_Developer »

I changed both input links to integer 10 on in the join stage. Had the same result.

I dind't see the condition in the join stage. I looked under the general, properties, and advanced tabs
sud
Premium Member
Premium Member
Posts: 366
Joined: Fri Dec 02, 2005 5:00 am
Location: Here I Am

Re: Un-handled conversion error in a join stage

Post by sud »

DStage_Developer wrote:I changed both input links to integer 10 on in the join stage. Had the same result.

I dind't see the condition in the join stage. I looked under the general, properties, and advanced tabs
oops join stage ... i am sorry, it is there in lookup :!:

Also, please see the datatype in the output in the join stage. That should be integer as well.
It took me fifteen years to discover I had no talent for ETL, but I couldn't give it up because by that time I was too famous.
Post Reply