DELETE RECORDs from the DATASET



Compuware's data management products: File-AID for IMS, File-AID/MVS, File-AID for DB2 and DBA-XPERT for DB2

DELETE RECORDs from the DATASET

Postby fornanthakumar » Wed Jan 26, 2011 5:26 am

Hi,

I have dataset with millions of data. I just want to delete just 100 records from the dataset and i want to do it FILE-AID utility.

when was looking ahead in FILE-AID -> EDIT option and press enter it shows option for edit methods like below

Edit method ===> 2 (1 = Standard Edit; 2 = Windowed Edit)

If i choose option 1 -> Then i got error message "Insufficient storage" as Option 1 will load all the data into memory.

If i choose option 2 -> I cant delete records as options 2 does not support FILE-AID commands like INSERT,DELETE,REPEAT,SORT,COPY,MOVE,EXCLUDE
Regards,
Nanthu.Y.
fornanthakumar
 
Posts: 69
Joined: Fri Oct 22, 2010 1:58 pm
Has thanked: 0 time
Been thanked: 0 time

Re: DELETE RECORDs from the DATASET

Postby NicC » Wed Jan 26, 2011 10:42 am

OK. So? You cannot do it in File-aid. Use something else - a quick one-off program will probably do it faster than waiting for a debate on the forum to come up with an answer.
The problem I have is that people can explain things quickly but I can only comprehend slowly.
Regards
Nic
NicC
Global moderator
 
Posts: 3025
Joined: Sun Jul 04, 2010 12:13 am
Location: Pushing up the daisies (almost)
Has thanked: 4 times
Been thanked: 136 times

Re: DELETE RECORDs from the DATASET

Postby fornanthakumar » Thu Feb 24, 2011 1:28 pm

That is what i did finally.
Regards,
Nanthu.Y.
fornanthakumar
 
Posts: 69
Joined: Fri Oct 22, 2010 1:58 pm
Has thanked: 0 time
Been thanked: 0 time

Re: DELETE RECORDs from the DATASET

Postby ranga_subham » Tue Mar 01, 2011 9:30 pm

You would use DROP function of File-Aid batch to remove records based on selection criteria.

Note: The DROP function is not an update-in-place. The input and output files cannot be the same file.

Example-1:This example copies all of the input dataset records and drops any record that does not contain a valid 7-byte packed field beginning in location 4.
$$DD01 DROP IF=(4,7,NEP)



Example:-2This example copies the input dataset to the output dataset, and stops after dropping the first 200 records containing a valid packed field of any length, that begins in location 15, and has an arithmetic value equal to 1 or 2.
$$DD01 DROP IF=(15,EQ,P’1,2’),DROP=200


HTH.
ranga_subham
 
Posts: 279
Joined: Fri Jul 18, 2008 7:46 pm
Has thanked: 0 time
Been thanked: 1 time


Return to File-AID

 


  • Related topics
    Replies
    Views
    Last post