Hashfile-name

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
Jdrost
Participant
Posts: 17
Joined: Wed Jun 28, 2006 3:32 am

Hashfile-name

Post by Jdrost »

Hello,

Based on UtilityHashLookup I build a routine, but when I test the routine it fails to open the hashfile. I think I did not state the name and path of the hashfile correctly, but I do not know what I am doing wrong.

I know that the pathname of the hashfile that I need is "c:\hash" and the name of the hashfile is "TestHash". I passed the parameter as "c:\hash\TestHash" with the result I mentioned above.

When I look with windows explorer in that path I find a folder with the same name as the hashfile containing 3 .30-files. I do not know if that is the hashfile, but the hashfile seems to be in that place.

Can someone tell me how I state the name and path of the hashfile correctly in this routine?

Thanks in advance.
Kind regards,

Johannes Drost
loveojha2
Participant
Posts: 362
Joined: Thu May 26, 2005 12:59 am

Post by loveojha2 »

You need to create a pointer to the Hashed file so that it would have entry in the VOC file and after that you can access it using the pointer name, instead of the pathed file.
Success consists of getting up just one more time than you fall.
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

Johannes,

what error message are you getting from the routine when you try to open the file? A dynamic hashed file is created as a directory with the file name and it has 3 files - a .Type30, DATA.30 and OVER.30 so it looks as if the create portion was successful.
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

You basically have two choices.

One is to use OPENPATH to open the pathname. This sounds like what you need.

The other is to use SETFILE (a command, not a DataStage BASIC statement) to create a VOC pointer to the hashed file, then use OPEN to open it.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Post Reply