Thanks for your response John
The directory IS in the purge process and we have attempted to run it numerous times, only to receive a message (paraphrasing here) resources busy
We are assuming its because the directory is in perpetual use
Apologies for not making this point jn my previous e-mail

Alan Shore
E-mail : ASHORE@xxxxxxxx
Phone [O] : (631) 200-5019
Phone [C] : (631) 880-8640
'If you're going through hell, keep going.'
Winston Churchill

-----Original Message-----
From: MIDRANGE-L [mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of John Yeung
Sent: Thursday, January 21, 2016 6:04 PM
To: Midrange Systems Technical Discussion
Subject: Re: List IFS files in a folder using SQL (was: Those new SQL things on IBM i)

On Thu, Jan 21, 2016 at 5:18 PM, Alan Shore <ashore@xxxxxxxx> wrote:
[We have a giant IFS directory with millions of files that isn't being
purged.]

We have since included other directories into our ifs purge process,
and we hope that because the warehouse does not work from Friday night
to Sunday morning, this will give us time AND the necessary access to
this large ifs directory

OK, so... maybe this is a dumb question but... can you not just add this directory to your purge process and let it take its course?

Now that I have explained the dilemma, does anyone know if these sql services will have the capability of not only listing the contents, but also being able to delete the contents with certain criteria (age etc.) of a directory?

Well, if I've correctly understood the posts from other people, who are more familiar with the available views and services, there isn't as yet much if any IFS support. That was actually one of the main points I was trying to make in my post.

When I spoke of better IFS support in the future, I just meant that seems to be where IBM is heading. And that's my own, naive point of view. I don't have any insider information or anything.

For your particular issue, assuming that for whatever reason your existing purge process is not up to the task, I would recommend writing an IFS-centric script. Use Qshell or PASE. I'm guessing you just need something that works, not something that must be written solely in SQL.

(And if for some reason you do need to write solely in SQL, then you can just extend what I said to Jeff: use QSYS2.QCMDEXC, use QSH. You will just need to do more than simply list the names; you'll have to grab the timestamp info and delete as needed. But this is all achievable using the same overall approach of calling out to CL and in turn calling out to QSH.)

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

Please contact support@xxxxxxxxxxxx for any subscription related questions.


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

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.