Page 1 of 1

Posted: Thu Jul 03, 2003 9:30 am
by kduke
SMK

Hash files are considered to be a temporary holding area and should not be used like a real database. Most developers which have used DataStage for several years use the delete and create option. This is safest and fastest way.

If you really want to delete records then you can write a before job routine which executes a TCL statement. Normal SQL will work like:
delete from MyHashFile where key1 = 'whatever' and key2 = 'whatever';

Kim.

Posted: Sun Jul 06, 2003 8:22 pm
by dickfong
SMK

You may want to try

DELETEU FileVariable, RecordKey

if you want to delete the record in a DS routine.

Dick

Posted: Tue Jul 08, 2003 8:12 am
by WoMaWil
Hi,

If you use a UV-Stage instead of a hash-Stage you are even able to delete records with a job.


Wolfgang Huerter
=====================
Cologne, Germany

Posted: Tue Jul 29, 2003 5:27 pm
by ray.wurlod
Be aware that records in hashed files are not date-stamped. Therefore, unless one of the fields within each data record contains a date-stamp of some kind, there is no mechanism for identifying the records that you might want to delete.
For example, the DataStage job logs are hashed files but, in this case, there is a field called TIMESTAMP that is used by the purge utilities.

Ray Wurlod
Education and Consulting Services
ABN 57 092 448 518