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



Mikael,

This can be a really hot topic on this list.  Check the archives for both
RPG and Midrange.  There should be a lot of information for you there.

Having said that, IMHO there is no difference if you are working on sets of
records and have the necessary access paths created for your SQL statements.
We recently went through an evaluation process in our shop where we looked
at using SQL in our applications.  As part of this process I ran some tests
comparing batch processing of a large (200+ mil. records) file with both SQL
and several RPG variations.  It was our determination that there was no
significant difference in the run times.  If you are going after a single
record or a small group of records (items on an order for instance)
repeatedly I would expect the RPG solution to perform better because of
repeated overhead with the SQL statement.

HTH,

Rick

-----Original Message-----
From: Mikael Salo [mailto:mikael.salo@xxxxxxx]
Sent: Monday, May 19, 2003 2:54 AM
To: rpg400-l@xxxxxxxxxxxx
Subject: When should one use SQL/RPG?

Hi everybody!
I've been told that in some cases SQL is more efficient that RPG and
vice versa. However, I did not get any clear answer on that so I turn
to you out there and ask the same thing. When is embedded SQL
a better choice than RPG and when should one use RPG instead?

I've done embedded (prepared) SQL statements and fancy it because it's
easy to read and understand, some of my colleagues have an other opinion
though and their answer is more or less that RPG is always better. It is
from
my point of view not an answer that is convincing me enough that it is
the case.

Any general guidelines? Anything to say about compiler issues?

Thanx in advance,

Mikael Salo

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

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.