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



McKown, John wrote:
McKown, John wrote:

This is just curiosity on my part. From previous responses,
I know that I can ftp a physical file (equivalent to a DB2
table on other systems). If I need the information in the PF,
but reformatted in some way (such as packed decimal as zoned
or binary integer as zoned), can I just create an LF and
then ftp the LF? If so, I would hope this would give me the
data in the PF, but "reformatted" and "selected" as specified
in the LF. True?
Jim Essinger wrote:

I don't think that the LF would reformat the data from packed to zoned, though I have never had reason to try. I would create a
zoned version of the file, and copy the data. The i will map the
data to the new formats.

That would be easy. But if I could use an LF, that would be even
easier because I wouldn't need to "refresh" the zoned copy. And I
am a 110% believer in "easy" <grin>.

An LF can use supported mappings to reformat the physical data; packed to zoned is supported, but be aware that the /preferred positive/ sign nibble differs between the systems, so the COBOL must treat the BCD for what it is; i.e. as Binary Coded Decimal, not character data. Even an OPNQRYF ODP can be used to PUT or APPEND the data from the DB2 for i, or to GET from the other system. That even enables dynamic selection from one version of the "reformatted" file without creating a new file for each variation of its "selected" data. The SQL VIEW is my preference for type of LF to use, but if the COBOL flat-file recipient expects ordered records, the SQL VIEW is not an option directly, unless the COBOL intends to sort too. However the OPNQRYF ODP can be used on the SQL VIEW to establish the KEYFILE specifications for ordering.

Regards, Chuck

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