Some caution is warranted, though... The SQL that comes out of RTVQMQRY
is not always quite right, especially when running this command on a
Query/400 (not QMQuery) objects. Join file types are often NOT
translated correctly, for example. If you're using this to learn SQL,
you will be led astray.
Eric DeLong
-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx
[mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of
elehti@xxxxxxxxxxxxxxxxxx
Sent: Tuesday, May 12, 2009 4:43 PM
To: midrange-l@xxxxxxxxxxxx
Subject: secret way to get to SQL statements that Query/400 (WRKQRY)
uses in*QRYDFN objects
Lest we forget the secret way to get to SQL statements that Query/400
(WRKQRY) uses in *QRYDFN objects:
http://www.itjungle.com/fhg/fhg052604-story01.html
RTVQMQRY QMQRY(library/query)
SRCFILE(library/QQMQRYSRC)
SRCMBR(*QMQRY)
ALWQRYDFN(*ONLY)
When this command completes, you will be able to view or edit the
generated SQL statement as you would any other source file member