Difference between revisions of "SQLRPGLE"

From MidrangeWiki
Jump to: navigation, search
(RPG IV with Embedded SQL)
Line 1: Line 1:
 
[[Category:RPG]]
 
[[Category:RPG]]
 
[[Category:SQL]]
 
[[Category:SQL]]
 +
[[Category:SQL]]
 +
[[Category:RPG]]
 
= RPG IV with Embedded SQL =
 
= RPG IV with Embedded SQL =
 
== Introduction to RPG IV with Embedded SQL==
 
== Introduction to RPG IV with Embedded SQL==

Revision as of 16:48, 29 June 2005

RPG IV with Embedded SQL

Introduction to RPG IV with Embedded SQL

SQL is a powerful tool in any programmer's skill set. It is possible to leverage this tool from within RPG (& other languages). The source member type for these programs is SQLRPGLE. Here is an example of an embedded SQL statement:

     C/EXEC SQL
     C+ SELECT * FROM mylib/myfile
     C/END-EXEC
SQL Directives
Directive Function performed
SELECT The Select directive is used to extract data from a Physical file or Table