Bingo! Thanks Buck - that last link is what I was looking for. It shows what the flags mean, and now I can at least tell if I'm dealing with a join logical. Unfortunately I don't see anything that corresponds to the DSPFD

 SQL file type . . . . . . . . . . . . . . . :            VIEW

And after some debugging, it appears the flags don't help at all. DSPFD shows the file as a logical, created with CREATE VIEW that's a SELECT a FROM b JOIN c WHERE d = 'e', but according the the INFDS flags, it's a physical file member, not a join logical member.

Well, looks like I can use SYSTABLES to at least determine if it's a view or not.


On 10/10/2017 1:10 PM, Buck Calabro wrote:
On 10/10/2017 3:26 PM, Peter Dow wrote:

Specifically what I'm looking for is a way to determine
if the file just opened is an SQL view, not a DDS logical
file. It turns out that the number of records on open
(pos.156-159 of the INFDS) is incorrect if the
SQL view was created with a WHERE clause.
I don't think that information is in the Open Feedback area. Perhaps
you could exchange the INFDS for a SELECT COUNT(*) INTO... for all file
types?


The following is how I came to that conclusion. Feel free to delete now.

I'm trying to find a description of the contents of the file information
data structure contents.

IBM's Knowledge Center helpfully tells me "A description of the contents
of the open feedback area, and what file types the fields are valid for,
can be found in the iSeries Information Center."

And the iSeries Information Center says its contents have been moved to
the Knowledge Center.
I'm guessing it's RPG you're looking for?
Programming > ILE languages > RPG > ILE RPG Reference > RPG IV Concepts
File and Program Exception/Errors > File Information Data Structure
https://www.ibm.com/support/knowledgecenter/ssw_ibm_i_73/rzasd/filinda.htm

The Open Feedback does indeed tell me that the description is in the IBM
i Information Center. Pity there's no link; not even IBM can maintain
all those moving parts. Searching for 'Open Feedback' did return this
helpful link: 'Monitoring file status with the open and I/O feedback
area'
https://www.ibm.com/support/knowledgecenter/ssw_ibm_i_73/dm/rbal3openiofba.htm
Which has the link to the Open Feedback structure:
https://www.ibm.com/support/knowledgecenter/ssw_ibm_i_73/dm/rbal3feedb.htm
The path to that is Files and file systems > Database file management >
Reference > Feedback area layouts > Open feedback area

--buck



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.