×
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.
Jonathan,
Please remember that not only "ORDER BY" fields important in your
statement in determining what access path to use but also so are "WHERE"
fields. Now, an existing logical file may have been created using DDS.
And it may have Select/Omit logic. A common use of Select/Omit logic is
"active record" fields.
When you ran that in debug were these fields part of the recommended
access path? What was the exact recommended access path? I think you'll
find that WHERE trumps ORDER BY as far as recommended fields in the access
path.
Also, if you didn't use the existing logical file, but instead used the
physical file itself, what, (if anything), would you have changed in your
selection criteria?
For example, you may have a logical that selects only those rows with IID
= 'IM' and then orders by IPROD. SQL will recommend that you create in
index by IID, IPROD if your sql statement looks like
Select ...
From IIM
where IID='IM'
Order by IPROD
Rob Berendt
As an Amazon Associate we earn from qualifying purchases.