× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Thanks Rob

Worked like a charm
These are giants indeed.

Gad


date: Wed, 12 Jan 2022 12:19:20 +0000
from: Rob Berendt <rob@xxxxxxxxx>
subject: RE: Delete old IFS files

Frostie was a snowman.
Forstie is the guy you're thinking of. That should make a huge difference
in searching.

This line below is standing on the shoulders of giants and I've not broken
it down. Basically it blasts all files, in the directory specified, over 5
days since modified
STRQSH
find /www/apachedft/logs -mtime +5 -type f -print | xargs /bin/rm -f

If you want to do it in SQL there are functions like the following to find
IFS files and you can do your own thing based on dates and other criteria
returned.

https://www.ibm.com/docs/en/i/7.4?topic=services-ifs-object-statistics-table-function
You may have to write a Stored Procedure Language or SPL to process the
results by using the QCMDEXC procedure at
https://www.ibm.com/docs/en/i/7.4?topic=services-qcmdexc-procedure
Or you can build a string on the fly and process it with only a select by
using the qcmdexc scalar function at
https://www.ibm.com/docs/en/i/7.4?topic=services-qcmdexc-scalar-function

You may be able to search for examples using QCMDEXC in a SPL. Run SQL
Scripts have some examples.

Rob Berendt
--
IBM Certified System Administrator - IBM i 6.1
Group Dekko
Dept 1600
Mail to: 7310 Innovation Blvd, Suite 104
Ft. Wayne, IN 46818
Ship to: 7310 Innovation Blvd, Dock 9C
Ft. Wayne, IN 46818
http://www.dekko.com


-----Original Message-----
From: MIDRANGE-L <midrange-l-bounces@xxxxxxxxxxxxxxxxxx> On Behalf Of Gad
Miron
Sent: Wednesday, January 12, 2022 3:20 AM
To: midrange-l@xxxxxxxxxxxxxxxxxx
Subject: Delete old IFS files

CAUTION: This email originated from outside of the organization. Do not
click links or open attachments unless you recognize the sender and know
the content is safe.


Hello guys

Sometime ago I have seen a SQL script to delete old IFS files (older then
30 days for instance)

Was it here on Midrange?
Was it a Scott Frostie jem?

Anyone in the know?

TIA
Gad
******************************************


As an Amazon Associate we earn from qualifying purchases.

This thread ...


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

This mailing list archive is Copyright 1997-2024 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.