Page 1 of 1

Problem witht the join stage

Posted: Tue Jan 16, 2007 3:55 pm
by sshettar
Hi All,

Well i have this job where i am joining 4 different files at different stages.

well the first two files are joined perfectly and i use this output file to join with the 3rd file . here i am haveing a problem . well i have this one field in the 3rd file which has values but after i join this file with the output of the first join i'm not getting any values for this field . it just appears as blank . i dunno if it is taking null or it is spaces.
but this is not the right output as this field should get values.
well this field CTN_CONFIG_NUM_FREE_FLOAT is of type varchar and length 8
and i 'm joining based on one field which is called Offer_id.
Any clue as to where i'm goin wrong


Thanks in advance

Posted: Tue Jan 16, 2007 4:17 pm
by us1aslam1us
Make sure you are having a match on the 'key' fields, if there is 'no match' then you will get 'null' values. Also check for spaces in your 'key' field.

Posted: Tue Jan 16, 2007 4:26 pm
by sshettar
Well there are matching records , that is why the other fields are displaying values . only this field is not displaying values.

Any Clue why this is happening ?

Posted: Tue Jan 16, 2007 4:31 pm
by us1aslam1us
field CTN_CONFIG_NUM_FREE_FLOAT is of type varchar and length 8
Have you made any changes to the Data-Type or Length of this field. Also post some sample data.

Posted: Tue Jan 16, 2007 4:51 pm
by sshettar
No i havent changed the data type nor the length . it is the same as what it is in the source file.

well the sample data at the source is here below
Promo_ID Offer_ID Buy_Cart Get_Cart CTN_CONFIG_NUM_DEALS CTN_CONFIG_NUM_FREE_FLOAT
00003453 00005263 1 1 0 0
00003507 00005320 0 1 5 0
00003549 00005344 1 1 0 0

Well at the output all the above fields are displaying its value but for the last field ie CTN_CONFIG_NUM_FREE_FLOAT which appears blank .

is this information enough ?

plz need help on this


Thanks in advance

Posted: Tue Jan 16, 2007 4:57 pm
by us1aslam1us
How are you sorting and partitioning the data?

Posted: Tue Jan 16, 2007 5:00 pm
by sshettar
i'm doin a hash partinoning and the key fieldfs are the same as the keys used to join the two files.

ie the Offer_Id
and Promo_Id

Posted: Tue Jan 16, 2007 5:20 pm
by kumar_s
Were the data been joined based on the key? what is the job desing? What is the stage right after Join stage? Is it 0 or blank?

Posted: Tue Jan 16, 2007 5:26 pm
by sshettar
well the job design is as follows
i need to join 4 files
the first join is between the files
Kit_Param and Offer_Pcking
this join is done based on the keys Offer_Id and Promo_Id
here i'm getting few fields from the Kit_Param file and few from Offer_Pcking file

the key columns are mapped from the offer_Pcking file


now the output of this file has to be joined with the offer file
based on the same two key columns
and here again i'm getting all the fields from the output file and few from the offer file.
the problem is with the field from the offer file which is not getting displayed.
it is blank . its not showing any data

i guess i'm clear now?

Thanks in advance

Posted: Tue Jan 16, 2007 5:32 pm
by kumar_s
It shows that you data is not joined based on the given key columns. Not sure if you are the one who created the other post for unsucessfull join in Join stage. There are factors like, Sorting order, Partition, data type.... Pls do a search. If you feel that you have mentioned all parameters correctly, list those setting here. Ensure you have the correct data for join.

Posted: Tue Jan 16, 2007 11:37 pm
by vivekreddy
Sort the data in both input sets to the join stage(s) on the join key(s) before sending it to the join stage(s). And before sorting the respective data sets, clear the partitioning applied in the immediately preceding stage (s).
I had the same problem, and this worked for me.
Please let me know whether this works for u as well.