We have several hundred thousand products in our inventory file and have no problem searching via SQL. The best way to find out what is going on is to turn on the query optimizer debugging messages and run the query. The Visual Explain tool in iSeries Navigator puts a nice UI on them but you can get what you need just by looking at job logs.
There should be posts in the archives on how to do this and I think using Visual Explain has already been suggested.
Matt
-----Original Message-----
From: rpg400-l-bounces@xxxxxxxxxxxx [mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of Abacusflorida@xxxxxxx
Sent: Monday, November 24, 2008 4:31 PM
To: rpg400-l@xxxxxxxxxxxx
Subject: Re: iSeries data access
I have also had a similar experience when the website authors send an SQL
statement to extract inventory from our AS/400. I've found that a search of
the entire file via SQL rather than equivlent SETLL & READ is the problem.
I've been told that setting up a logical over the physical inventory file would
help, but have not had any significant improvement, if any. Perhaps you
could check your file by placing an invalid record in the table beyond the record
you think should be searched via SQL If the statement bombs you will know
that it looks at the entire database file. Ours is a small inventory file,
about 20,000 records. I don't know what others experience with a larger invento
ry databas. Any suggestions anyone? Thanks
Warren
**************One site has it all. Your email accounts, your social networks,
and the things you love. Try the new AOL.com
today!(
http://pr.atwola.com/promoclk/100000075x1212962939x1200825291/aol?redir=http://www.aol.com/?optin=new-dp
%26icid=aolcom40vanity%26ncid=emlcntaolcom00000001)
--
This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing list
To post a message email: RPG400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit:
http://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at
http://archive.midrange.com/rpg400-l.
As an Amazon Associate we earn from qualifying purchases.