× 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.



Dave,

As much as I prefer to do stuff in RPGLE over CL there are a few 
applications (like backups) where I'll stick with CL.  When doing so, 
sometimes having a Q&D method to execute CL comes in handy.  Several 
people use an old command from a magazine called RUNSQL.  Basically it is 
a QMQRY that is nothing but parameters and you pass it your entire 
statement.

STRSQL is not very conducive to a batch job based on CL.  And an 
interactive one that stops and presents a user with the STRSQL screen 
would go over like a turd in the punchbowl.

Building some stock queries for use with STRQMQRY is a possibility. 
However, instead of building a series of stock queries, why not use the 
qshell technique?  Granted, there might be a performance hit because of 
starting the environment, but is it a significant performance hit?  Most 
SQL I see imbedded into CL is a set, versus row, transaction, that is 
executed only once in the program.

To me, it's just another tool in the toolbox.  My only remaining question 
is "What about error trapping?".  But honestly, most of the sql I imbed 
into CL with RUNSQL I do no error trapping.  A lot of "assume" is done. 
And y'all know where that can lead.

Rob Berendt

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
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.