On 11-Aug-2015 13:59 -0600, Johh R. Smith, Jr. wrote:
I am looking for a system file that contains the following fields.
I know this can be obtained via DSPFD or APIs but the DSPFD option is
taking forever because the library is huge
Which invocation of the Display File Description? Was the request
coded to limit to only the [one or two] File Attribute (FILEATR) of
interest and eliminating DDMF ensuring System (SYSTEM) of Local (*LCL)?
If using *MBRLIST, then try the *MBR instead; IIRC the latter can use
a feature to limit faulting by asking to pre-load members into memory
rather than faulting them into memory, and that the former can not take
advantage of that ability despite having a much faster listing
capability [using effectively, the Materialize Context (MATCTX)].
FWiW the best results I have had for /large/ libraries is to first
get the list of files using whatever method [e.g. *DBXREF or DSPFD] and
then running several parallel requests in submitted batch jobs against
those files that have /many/ members, and then serially against each of
the files with just one or /few/ members; the concurrency helps greatly,
and if the request runs interactive then having moved the requests with
more faulting and higher memory requirements avoids the memory
limitations encountered in the interactive environment.
and I haven't spent the time on the API yet to see how slow it is. I
was hoping someone knew of a file that already had the data and I
could just read it.
The SYSPSTAT [others already responded using the long-name
SYSPARTITIONSTAT] VIEW is effectively a means to defer the request to
the API without actually having to code to the API; i.e. the OS
essentially has already done that. The biggest benefit [and possible
fault per increased memory requirements in possible conflict] is that
the API can be invoked against multiple files simultaneously using
database\query threads. I do not recall, but I believe the effect is an
invocation of a User Defined Table Function (UDTF) per file-name.