Creating and reading the hash file in the same job

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

Post Reply
swathi Singamareddygari
Participant
Posts: 48
Joined: Fri Feb 29, 2008 1:09 am
Location: Bangalore

Creating and reading the hash file in the same job

Post by swathi Singamareddygari »

Hi,

I want to design a job in such a way that,have to create the hash file in the first transformer and in the next transformer i have to use it as lookup.
when i designed like this ,job is failing saying that not able to open the hash file.

so is there any settings need to follow ,so that hash file will get created before going to the next stage.
Thanks&Regards
S.Swathi
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Create it how? Empty or populated? Typically one would do that in the same transformer to avoid this very issue, the hashed file would have both an input link and a reference link to it.
-craig

"You can never have too many knives" -- Logan Nine Fingers
SURA
Premium Member
Premium Member
Posts: 1229
Joined: Sat Jul 14, 2007 5:16 am
Location: Sydney

Re: Creating and reading the hash file in the same job

Post by SURA »

Very first run you need this file to be created. For the rest of the run you don't want. My advise is to create a dummy file before run this job as a one go is easy.

still if you want, you can use a logic to create a dummy file in the same job and then use it.

DS User
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Or you could use a before-job subroutine (ExecTCL) to create the hashed file. It will, of course, be empty of both data and metadata if you do it this way, but it will still work.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Re: Creating and reading the hash file in the same job

Post by chulett »

SURA wrote:Very first run you need this file to be created. For the rest of the run you don't want.
Default behaviour when writing to a hashed file.
-craig

"You can never have too many knives" -- Logan Nine Fingers
Post Reply