Page 1 of 1

Enable Selection tab in Hash Stage for Remote Hash File

Posted: Fri Feb 11, 2005 3:19 pm
by willpeng
All:

I researched a lot of people's post about mkdbfile, setfile, and hash file, but I got bits and piece of info. So I am posting to see if anyone can help me understand this a bit more so I can enable the selection tab in the hash stage for Remote Hash File without too much manual process.

The background of what i am doing is this:

I am upgrading an older DS6 system to DS7 system. New guideline requires all hash files be pathed and remote.

I was able to convert all the account setting to directory setting editing the dsx file.

I create the remote hash file using mkdbfile and use setfile to put it. Everythng works well except those hash files that has a selection setup.

My understanding is that the selection is a pick feature and require a dictionary to be created. I did see D_Hashname files created by DS, but for some reason it is not using it.

What am I missing here? do I need a setfile on the D_Hashname too? I really do not wish to manually create Dict files for each hash files. There are over 200 jobs that uses selection and who knows how many hash files within a job has. And I need to do it again when this goes to production.

Any suggestion?

Posted: Fri Feb 11, 2005 6:01 pm
by ray.wurlod
No, mkdbfile does create the dictionary component, and SETFILE includes a pointer to it. You can prove this with a command such as

Code: Select all

LIST.DICT hashedfilename
The thing that doesn't happen when you use mkdbfile is the creation of column definitions within the file dictionary (after all, it's got nowhere to get them from). If you create the hashed file from DataStage, it has the table definition and can build the dictionary from that. But if you use mkdbfile manually, you also have to build the file dictionary manually. Search the forum for INSERT INTO DICT

Posted: Sat Feb 12, 2005 2:53 pm
by willpeng
After searching the forum, I found out that you can create the file dictionary content without coding by validating the job. So that is what I did, but I still can't get the selection tab in the hast file stage to be active.

Also, how I verify if the dict content is created by validating?

Any idea?

Posted: Sat Feb 12, 2005 5:02 pm
by ray.wurlod
The Selection tab is never enabled if you are using the hashed file on a reference input link. Being local or remote is irrelevant. There is no reason that the Selection tab would be disabled on a stream input just because the hashed file is not in an account.

At my current site we have the same rules about pathed hashed files, but the Selection tab is enabled on stream input links (7.1r1 on AIX).

Are you using the hashed file on a stream input link (solid line into Transformer) or on a reference input link (dashed line into Transformer)?

Re: Enable Selection tab in Hash Stage for Remote Hash File

Posted: Sat Feb 12, 2005 7:03 pm
by kcbland
willpeng wrote:I was able to convert all the account setting to directory setting editing the dsx file.
This is your mistake. You need to use the project setting, as it will then pick up the VOC entry created by SETFILE to file the path to the hash file.

The SELECT tab is only activated for jobs with the project setting selected. Your hash file isn't in the project, so don't be worried.

Posted: Sun Feb 13, 2005 3:07 pm
by ray.wurlod
I neglected to mention my personal standard #47; any job that creates a hashed file executes a SETFILE command to create the VOC pointer. And therefore can use the Account option and have the Selection tab enabled.
Sorry about that.

Posted: Sun Feb 13, 2005 11:11 pm
by kduke
You cannot post #47 without postig the other 46 standards. :wink:

Posted: Mon Feb 14, 2005 3:37 am
by ray.wurlod
If I posted all of those then anyone could command the same level of fees that I do. :P

And I worked hard to assemble these! :!:

Posted: Mon Feb 14, 2005 9:41 am
by chucksmith
William,

Look at my CreateVocPtr() routine on the DataStage Tools page of www.anotheritco.com .

In the Step02CreateInverseHashPart1 job, call the CreateVocPtr() routine as a Before-job subroutine. Do this on you Job Properties tab.

After the VOC pointer is created in Step02, the Step05 jobs will give you the selection tab if the Use Account Name button is pushed. All other steps may use Use Account Name or use directory path.

Posted: Mon Feb 14, 2005 10:11 am
by kduke
If I posted all of those then anyone could command the same level of fees that I do.
I seriously doubt that. We would just know 47 things Ray knows. How many posts do you have now and how many do you have left in you?

You do not need to post them. You have given us enough for one lifetime but please do not stop.

Posted: Tue Feb 15, 2005 1:13 pm
by willpeng
The Ascential guys told me to convert the remote directory location into an account. I'll see how that turn out.

Ray:
To answer you, it is streamed. Also, for some reason I am not seeing dictinoary D_hashname created on the remote directory when I use mkdbfile. I am using 7.1