×
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.
Yes, you can run a QMQRY in batch with a SBMJOB CMD(STRQMQRY etc.). You can
create these in a couple ways - use Query Manager (STRQM) and enter the
statement there. Or save your SQL session to a source member, delete
everything except the statement, and use CRTQMQRY on that source member. Or
just type the statement into a source member (RCDLEN 91 - can't use an
RPGLE source file).
Concerning performance, you need indexes to help this, but they can be hogs
for maintenance over large files. It'd help to have an index over SNTYPE
(probably is one), but I'd not think there is one over SNDESC. It's
probably having to read the whole blame thing. But could you use a date
field to narrow the range of records? See if there's an index on that and
put that criterion before the description one. STRDBG, CHGQRYA
QRYTIMLMT(0), run the statement to see what the optimizer does (cancel the
message you get). You'd want an index that has SNTYPE and the date in the
first 2 positions, then arrange your WHERE criteria in the order of the
fields in the key,
HTH
Vern
At 12:38 PM 1/21/2003 -0600, you wrote:
Dennis,
When I need to run SQL in batch, you've got a few choices. For very long
runs (more than a few hours), I'd put the statement in a source member and
submit a RUNSQLSTM command to execute it. For relatively quick queries
(hour or two) I'd use iSeries Navigator SQL tool. QM queries also have a
batch mode, as I recall.
Eric DeLong
Sally Beauty Company
MIS-Project Manager (BSG)
940-898-7863 or ext. 1863
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.