|
Paul, Is it possible for the compiler to associate an index with a view? Perhaps a F-spec keyword INDEX() to associate a specific access path to an open "view". I don't really know if it's possible, but it seems it could be managed. Eric DeLong Sally Beauty Company MIS-Project Manager (BSG) 940-898-7863 or ext. 1863 -----Original Message----- From: Paul Tuohy [mailto:tuohyp@xxxxxxxxxxxxx] Sent: Friday, July 23, 2004 4:36 PM To: Midrange Systems Technical Discussion Subject: Re: Views and Indexes Joel, "Only SQL defined indexes are really accessible by traditional I/O" - yeesh, I didn't put that very well! Traditional I/O in RPG usually (but not always) implies you are accessing by key (record address type of K on the F spec). You cannot specify the K for a view (since it does not have a key). You actually highlighted the "problem" with views - "the "where" and "order by" capability of a view". The problem is you cannot specify an order by for a view. When you can, life will be good :-). You cannot define an index over a view. When you can, life will be gooder :-) I agree thoroughly about the functionality of views - which makes it even more annoying that they are so difficult to use without embedded SQL. Guess I want the best of both worlds :-) Paul ----- Original Message ----- From: "Joel Cochran" <jrc@xxxxxxxxxx> To: <midrange-l@xxxxxxxxxxxx> Sent: Friday, July 23, 2004 6:06 PM Subject: Re: Views and Indexes > > Paul, > > I stand clarified :-) > > I didn't say that indexes and views were the same thing: I know what > capabilities a view has, but I was under the mistaken impression that > because of the "where" and "order by" capability of a view that it > represented the index as well. I looked it up and sure enough a view is > a "virtual table" that the underlying DBMS must execute at run time. > This means that it has to find its own indexes. So can you write an > index over a View? > > I still don't think a logical can compete with the functionality of a > view, but I'll admit I did under-represent them. "Only SQL > defined indexes are really accessible by traditional I/O" - what do you mean? > > Joel > http://www.rpgnext.com > -- This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list To post a message email: MIDRANGE-L@xxxxxxxxxxxx To subscribe, unsubscribe, or change list options, visit: http://lists.midrange.com/mailman/listinfo/midrange-l or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please take a moment to review the archives at http://archive.midrange.com/midrange-l.
As an Amazon Associate we earn from qualifying purchases.
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.