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



Interesting idea Dave, and with the precompiler people finally making some 
advancements maybe this will shortly be an option.  Otherwise you ran into 
too many precompiler issues.

Did anyone catch Han's wink about PPGENOPT?

Rob Berendt
-- 
"They that can give up essential liberty to obtain a little temporary 
safety deserve neither liberty nor safety." 
Benjamin Franklin 




Dave Boettcher <DBoettch@xxxxxxxxxxxxxxxx> 
Sent by: rpg400-l-bounces@xxxxxxxxxxxx
09/23/2003 03:38 PM
Please respond to
RPG programming on the AS400 / iSeries <rpg400-l@xxxxxxxxxxxx>


To
"'RPG programming on the AS400 / iSeries'" <rpg400-l@xxxxxxxxxxxx>
cc

Subject
RE: Egads! An area in which the precompiler people surpassed the compiler 
people!






So, if compiling at TGTRLS is important to you, 
there would be no reason why you could not make it an SQLRPGLE member
 and have the set option the only SQL in the program.

-----Original Message-----
From: Gina M Whitney [mailto:whitneyg@xxxxxxxxxx]
Sent: Tuesday, September 23, 2003 3:10 PM
To: rpg400-l@xxxxxxxxxxxx
Subject: Re: Egads! An area in which the precompiler people surpassed
the compiler people!



rob@xxxxxxxxx wrote:
 The SQL  SET OPTION is SQL's version of the H spec.

 For example:
      C/EXEC SQL
      C+ Set Option
      C+     Naming    = *Sys,
      C+     Commit    = *None,
      C+     UsrPrf    = *User,
      C+     DynUsrPrf = *User,
      C+     CloSqlCsr = *EndMod
      C/END-EXEC

 Here's something you can do in a SET OPTION that you cannot do on an H
 spec.  Why?
      C/EXEC SQL
      C+ Set Option
      C+     TgtRls = V5R1M0
      C/END-EXEC

 Rob Berendt

Hans wrote:
Will wonders never cease, eh?

I don't know how the SQL prep works, but generally, the RPG command
options that you can't code on the H-Spec are disallowed there
because we're already knee deep into the compile already. In
particular, when you specify a different release on the CRTBNDRPG or
CRTRPGMOD command, a completely different program is invoked to
compile the source code. Since the H-Spec's are compiled by that
source code, it's meaningless to specify which version to use on the
H-Spec.

I suppose when the H-Spec parsing sees that a different compiler
version is requested, we could abandon the compile and tell the
command to invoke a different version of compiler. But then, how
would the compiler handle the following H-Specs:

H/if defined(*V5R2M0)
H   TGTRLS(*V5R1M0)
H/elseif defined(*V5R1M0)
H   TGTRLS(*V5R2M0)
H/endif
H*         ;-)

Cheers! Hans

=-=-=-=-=-=-=-=-=-=-=--=-
The SQL precompiler calls the same programs no matter the target release.
Since the SET OPTION statement must precede any other SQL statement,
setting the target release is allowed.   The precompiler calls the 
compiler
by generating a CRTBNDRPG or CRTRPGMOD command using the options specified
on the command and in the SET OPTION statement.  Therefore the compiler
knows the correct version before it gets deep into the compile.

In an upcoming release, watch for a new option in the SET OPTION 
statement.
I think you'll find it useful.

Gina


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

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.