View previous topic :: View next topic
|
Author |
Message |
pgte3
New User
Joined: 06 Feb 2009 Posts: 11 Location: USA
|
|
|
|
I am trying to delete every *.TEST.** dataset on a volume that begins with B, that has not be referenced in the last 120 days.
The LRDAYS>120 parm seems to be ignored, all *.TEST.** old and new are deleted.
Can not seem to get it coded correctly.
I have it coded as follows:
Code: |
//FDRDEL JOB CLASS=S,MSGCLASS=Q
//JOBLIB DD
//DELSTEP EXEC PGM=FDREPORT,REGION=0M
//SYSPRINT DD SYSOUT=*
//SYSPUNCH DD SYSOUT=(A,INTRDR)
//FDRLIB DD DSN=TECH.PTE.JCL,DISP=SHR
//SYSIN DD *
XSELECT XDSN=*.TEST.**,LRDAYS>120
XEXCLUDE VOL=(A*,C*,D*,F*,E*,Z*)
PUNCH MASKNAME=FDRDELM,ECHO
PRINT DATATYPE=CATALOG,RPTYPE=SELPCH |
Thanks |
|
Back to top |
|
|
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 8797 Location: Welsh Wales
|
|
|
|
I can only assume that the way in which you have presented your statement, that there really is a question in there somewhere. OK, so maybe today IS psychic day ........... so here we go.
I know that using DFdss that the last referenced date is either an absolute or relative date and is dead easy to use. With Dfdss you can also backup and delete at the same time.
However, from some very very old examples in my archive
LRDAYS.GE.(nnn)
Obviously the systax may have changed since my code was last used, but you did check in the manual first .......... didn't you ? |
|
Back to top |
|
|
pgte3
New User
Joined: 06 Feb 2009 Posts: 11 Location: USA
|
|
|
|
Thanks for the reply expat. Sorry about the ambiguity, I guess I could have should have wrote the sentence "Can not seem to get it coded correctly." as "Can not seem to get it coded correctly, any suggestions on how to coded it correctly".
I will look into the differences of coding LRDAYS.GE.(nnn) vs. LRDAYS>120, on the surface they would seem the same.
The LRDAYS>120 is the technique in the FDR manual. |
|
Back to top |
|
|
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 8797 Location: Welsh Wales
|
|
|
|
Well, if all else fails, try DFdss |
|
Back to top |
|
|
Pete Wilson
Active Member
Joined: 31 Dec 2009 Posts: 582 Location: London
|
|
|
|
You are using DATATYPE=CATALOG rather than DATATYPE=VTOC or CATVTOC. The last-reference-date information is in the VTOC not the usercatalog. |
|
Back to top |
|
|
|