Delimiting SQL in a Program

Team-Fly    

 
DB2 Universal Database for OS/390 v7.1 Application Certification Guide
By Susan Lawson
Table of Contents
Chapter 5.  Using SQL in an Application Program

Delimiting SQL in a Program

In order to distinguish SQL calls from the rest of the program, delimiters are used. Although used in languages, the actual delimiters and methods differ considerably by language. For all languages using the standard precompiler, however, the methods are very similar. For example, use EXEC SQL and END-EXEC to delimit a SQL statement in a COBOL program:

 EXEC SQL  a SQL statement END-EXEC. 

NOTE

graphics/note_icon.jpg

For REXX, precede the statement with EXECSQL. If the statement is in a literal string, enclose it in single or double quotation marks.



Team-Fly    
Top


DB2 Universal Database for OS. 390 v7. 1 Application Certification Guide
DB2(R) Universal Database for OS/390 V7.1 Application Certification Guide (IBM DB2 Certification Guide Series)
ISBN: 0131007718
EAN: 2147483647
Year: 2002
Pages: 163
Authors: Susan Lawson

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net