|
Thanks for the FYI...I'm still happy...now to go cattle prod the infrastructure guys hehe.... Thanks, Tommy Holden -----Original Message----- From: rpg400-l-bounces@xxxxxxxxxxxx [mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of Gina M Whitney Sent: Tuesday, October 04, 2005 9:40 AM To: rpg400-l@xxxxxxxxxxxx Subject: RE: SQL finally "free'd"??? > Does it support multiple SQL statements per exec sql perchance??? > <drools> No. >Hopefully they've eliminated the need for /EXEC SQL and /END-EXEC >that's the most irritating thing. Having to code that for every line >of SQL is just as bad as /free and /end-free Each SQL statement must begin with EXEC SQL and end with a semicolon (;). The EXEC SQL keywords must be on one line. The remaining part of the SQL statement can be on more than one line. Example: An UPDATE statement coded in free form might be coded in the following way: EXEC SQL UPDATE DEPARTMENT SET MGRNO = :MGR_NUM WHERE DEPTNO = :INT_DEP; >Will it generate free format code? Or will it generate code like the >following? I suppose I really shouldn't care about what it does under >the >covers. My only concern is if this kind of stuff was what was limiting >some variable types like dimensioned qualified data structures such as >MyDivision(x).MyPlant(y).MyLocation(z) > >C*EXEC SQL >C* Fetch C1 into :InliblTbl.InliblLib >C*END-EXEC >C Z-ADD -4 SQLER6 >C CALL SQLROUTE >C PARM SQLCA >C PARM SQL_00006 >C SQL_00009 IFEQ '1' >C EVAL INLIBLTBL.INLIBLLIB = SQL_00011 >C END No, it writes out fixed form. Reading and writing are two completely different processes. Variable types like dimensioned qualified data structures are not supported in SQL syntax. It has nothing to do with the precompiler code. -- 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 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.