One more lookup problem

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

talk2shaanc
Charter Member
Charter Member
Posts: 199
Joined: Tue Jan 18, 2005 2:50 am
Location: India

Post by talk2shaanc »

Or if you want to avoid adding the hash file to VOC. Make a copy of UtilityHashLookup and change the command given after comment
* Table is not in cache of opened tables, so open it.

Code: Select all

Change From:   Open HashTable 
Change To:     OpenPath HashTable 
You are now good to go, no hasle of adding the hash file to VOC.
Arg1 = Full Hash file path
Arg2= Key
Arg3= column position to return.
Shantanu Choudhary
prasad111
Premium Member
Premium Member
Posts: 173
Joined: Fri May 19, 2006 10:53 am

Post by prasad111 »

ShaneMuir wrote:But how are limiting the output?
Each time in your examples, you are only showing one output but you have said that its possible the constricting value could be 'source' or 'select' or many others. How are you determining which value the output is to be restricted by? Ie Are you only ever wanting one output or are you wanting more than one?
It is tough to explain in the example I have given above, lets assume that the 'select' selection will be in a different column derivation............
prasad111
Premium Member
Premium Member
Posts: 173
Joined: Fri May 19, 2006 10:53 am

Post by prasad111 »

talk2shaanc wrote:Or if you want to avoid adding the hash file to VOC. Make a copy of UtilityHashLookup and change the command given after comment
* Table is not in cache of opened tables, so open it.

Code: Select all

Change From:   Open HashTable 
Change To:     OpenPath HashTable 
You are now good to go, no hasle of adding the hash file to VOC.
Arg1 = Full Hash file path
Arg2= Key
Arg3= column position to return.
Arg2 if you harcode the Arg2 it will only return output of one column, otherwise you have to use ((Arg1, Arg2, Arg3) or (Arg1, Arg2, Arg3) or (Arg1, Arg2, Arg3)....................)it will be a very big one
As I said the Table 2 is manually entered and maintained table, if someone changes the key value after 6 months....................it will take hell out of time to fix the problem(you can tell it has a maintaince issue will occur in longer term perspective)
ShaneMuir
Premium Member
Premium Member
Posts: 508
Joined: Tue Jun 15, 2004 5:00 am
Location: London

Post by ShaneMuir »

prasad111 wrote:
ShaneMuir wrote:But how are limiting the output?
Each time in your examples, you are only showing one output but you have said that its possible the constricting value could be 'source' or 'select' or many others. How are you determining which value the output is to be restricted by? Ie Are you only ever wanting one output or are you wanting more than one?
It is tough to explain in the example I have given above, lets assume that the 'select' selection will be in a different column derivation............
Well the more you tell us, the more we may be able to help.

The only reason I ask the above question is: If you are not going to be selecting more than one of the filtering values ie "Source", "Select" when you are running the job then that value could be a parameter that is passed to the job. That way you can have the one hash file.
Post Reply