Hi All,
I have a problem in hashed File.I have an hashed file which has 3 input links.All of them write into the same hashed file..Eg;PartitionHash.
Input1.SaleDay Partition Information.(PYYYYMMDD)
Input2.SaleWeek Partition Information(PYYYYMMDD)
Input3.SaleMonth Partition Information.(PYYYYMM)
The above 3 inputs use thesame hashed file PartitionHash. For each input i checked the Deletefile before create option.All of them pointing to the same File.
So when a job is run a second time it still writes out the records from the first run. I added a step earlier in the job to clear the hashes.
by passing @NULL to the columns of HashedFile before writing the records..and removed the option DeleteFile..No luck.
So how can we handle this situation in DS? Please advise.
Satheesh.
Hashed File record Clearance
Moderators: chulett, rschirm, roy
-
- Participant
- Posts: 182
- Joined: Thu Jun 16, 2005 2:05 am
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
Use ExecUV as a before-job subroutine. Execute a CLEAR.FILE command to clear all records from the hashed file. Change your Hashed File stages so that they do not delete before writing.
If you have created the hashed file in a directory you will need to create a VOC pointer to it using a SETFILE command in order for the CLEAR.FILE command to work.
If you have created the hashed file in a directory you will need to create a VOC pointer to it using a SETFILE command in order for the CLEAR.FILE command to 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.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
-
- Participant
- Posts: 182
- Joined: Thu Jun 16, 2005 2:05 am
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
Issue both CLEAR.FILE commands adjacently in the Administrator client Command window. Then select both commands from the history pane and click Save. You will be prompted for a name under which to save, I suggest something meaningful like CLEAR_TWO_HASHED_FILES. Then, in your job, execute CLEAR_TWO_HASHED_FILES using the ExecUV before-job subroutine, rather than a CLEAR.FILE command.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.