Glenn,
Ok. But I was more interested in thoughts on what the directory was for
and other stuff from the handout.

On Fri, Mar 20, 2026 at 6:02 PM Glenn Gundermann <glenn.gundermann@xxxxxxxxx>
wrote:

Hi Rob,

Instead of deleting the contents of a folder first, you can
add SUBTREE(*ALL) to the RD.

Yours truly,

Glenn Gundermann
Email: glenn.gundermann@xxxxxxxxx
Cell: (416) 317-3144




On Fri, 20 Mar 2026 at 15:51, Rob Berendt <robertowenberendt@xxxxxxxxx>
wrote:

Thoughts on the following:


*-- Based on the handout available at


https://learn.common.org/products/sql-for-system-and-storage-management#tab-product_tab_handouts
<

https://learn.common.org/products/sql-for-system-and-storage-management#tab-product_tab_handouts
*
*-- Delete objects first.*SELECT 'DEL OBJLNK(''' *CONCAT* PATH_NAME
*CONCAT*
''')',
QCMDEXC('DEL OBJLNK(''' *CONCAT* PATH_NAME *CONCAT* ''')'),
IFS.*
FROM TABLE (
QSYS2.IFS_OBJECT_STATISTICS('/QIBM/UserData/OS400/SQE',
OBJECT_TYPE_LIST *=>* '*ALLSTMF')
) IFS
WHERE OBJECT_CHANGE_TIMESTAMP < *CURRENT TIMESTAMP* - *100* *DAYS*
;

*-- Delete directories next*SELECT 'RD DIR(''' *CONCAT* PATH_NAME
*CONCAT*
''')',
QCMDEXC('RD DIR(''' *CONCAT* PATH_NAME *CONCAT* ''')'),
IFS.*
FROM TABLE (
QSYS2.IFS_OBJECT_STATISTICS('/QIBM/UserData/OS400/SQE',
OBJECT_TYPE_LIST *=>* '*ALLDIR')
) IFS
WHERE OBJECT_CHANGE_TIMESTAMP < *CURRENT TIMESTAMP* - *100* *DAYS*
AND PATH_NAME <> '/QIBM/UserData/OS400/SQE'
;
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing
list
To post a message email: MIDRANGE-L@xxxxxxxxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives
at https://archive.midrange.com/midrange-l.

Please contact support@xxxxxxxxxxxxxxxxxxxx for any subscription related
questions.


--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives
at https://archive.midrange.com/midrange-l.

Please contact support@xxxxxxxxxxxxxxxxxxxx for any subscription related
questions.



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2026 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.