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



IMO...

Whether or not the SQL is faster or slower than RPG depends on what you do
with the parsed results.

If you're going to consume the parsed results in RPG, than an efficiently
written RPG routine would likely perform faster.

If you're going to consume the parsed results in the same SET based SQL
statement, than the SQL would likely perform faster (i.e. the parse
function is called as part of the same SQL query consuming the parsed
results). This would likely result in a smaller volume of code as well,
because SQL is handling all the glue necessary to tie the parse to the
consumption. In RPG, you have to supply said glue code and memory
definition to store the parsed results.

Our shops should have both an RPG and an SQL solution for such a common
thing as parsing a delimited string.

Mike

On Mon, Jan 15, 2018 at 10:23 AM, Jon Paris <jon.paris@xxxxxxxxxxxxxx>
wrote:

Birgitta has supplied an example. Others have mentioned Scott's RPG
Service routines.

Both - I strongly suspect - will be faster than the SQL approach and
certainly easier to understand and modify.


Jon Paris

www.partner400.com
www.SystemiDeveloper.com



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

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.