× 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.



rob@xxxxxxxxx wrote:
Summary: A ftp download of a PF will sort the data. Download
of a stream file will not. <<SNIP>>

Of course the FTP does not really "sort" the data, the PUT or GET of data to\from the keyed LF or PF merely /returns the data/ in the order of the [primary] key of the file. That effect is much the same as how when using the CPYF FROMRCD(*START), the data will be retrieved via the key sequence access path, whereas the FROMRCD(1) on CPYF effects data retrieval via the /arrival sequence/ access path. That FTP does not use SQL [non-relational, RLA], the default is to honor the key order on open [and thus retrieval], similar to DCLF\RCVF of a CLP.

If, however, I use the hated CPYTOIMPF command (your file
might be able to use CPYTOSTMF), I can do this:
CPYTOIMPF FROMFILE(ROB/ONECOLUMN) TOSTMF('/rob/onec.txt')
STMFCCSID(*PCASCII) RCDDLM(*CRLF)
<<SNIP implication of arrival sequence>>

Since the CPYTOIMPF uses SQL and because there is no ORDER BY in its implementation, there is no way to ensure that the order of its results will be in the arrival sequence as alluded in the example. So although there is no keyed STMF for ordered results of the FTP subcommands to copy the data, the STMF created by the CPYTOIMPF may be in [any seemingly random or even] a keyed order.

Regards, Chuck

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.