Use the SQL compiler option to enable the DB2 coprocessor capability and to specify DB2 suboptions. You must specify the SQL option if your COBOL source program contains SQL statements and it has not been processed by the DB2 precompiler.
| SQL option syntax |
|---|
|
Default is: NOSQL
Abbreviations are: None
If NOSQL is in effect, any SQL statements found in the source program are diagnosed and discarded.
Use either quotation marks or single quotation marks to delimit the string of DB2 suboptions.
You can use the syntax shown above in either the CBL or PROCESS statement. If you use the SQL option in the cob2 command, only the single quotation mark (') can be used as the string delimiter: -q“SQL('options')”.
related tasks
Programming for a DB2 environment
Compiling with the SQL option
Separating DB2 suboptions
related references
Conflicting compiler options