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



Bartell, Aaron L. (TC) wrote:

I am trying to make use of "qualified field names"  by using Extname on an
externally defined file.  Here is the code, and I can't get it to compile to
V5R1 even though it is in the V5R1 manuals
(http://publib.boulder.ibm.com/iseries/v5r1/ic2924/books/c0925083.pdf page
273).  "The parameter for keyword PREFIX is not valid; keyword is ignored."

I saw some questions on this in the archives which made be believe that is
shouldn't work at V5R1, but why is it in the V5R1 manuals then?


FLiblPF IF E K DISK Prefix('Libl.')
D Libl E DS Qualified ExtName(LiblPF)
/Free
*InLR = *On;
/End-Free


Here's the file. . .

     A          R LIBL
     A            DIV            3  0       COLHDG('Division')
     A            SUBDIV         3  0       COLHDG('Sub Division')
     A            ID            20A         COLHDG('Unique Id')
     A            SEQ            4  0       COLHDG('Sequence')
     A            LIB           10A         COLHDG('Library')

A K DIV
A K SUBDIV
A K ID
A K SEQ



There are two problems. The following program fixes both:


----------------------------------------------------------------
FLiblPF    IF   E           K DISK    Prefix('LBL.')
D Lbl           E DS                  Qualified ExtName(LiblPF)
 /Free
    *InLR = *On;
 /End-Free
----------------------------------------------------------------

That is, first, if a literal, the PREFIX parm must be upper-case. Second, the data structure has the same name as the record.

Cheers! Hans



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.