Previous Topic Next topic Print topic


OPTION (deprecated)

Enables non-default optional behavior.
Restriction: This topic applies to Windows environments only.
Note: OPTION is deprecated, and supported for backward compatibility only. We recommend that you use equivalent HCOSS SQL compiler directive options instead.

Syntax:

OPTION={CHECKCALLPARAMS | SQLCLRTRANS}...

Parameters:

CHECKCALLPARAMS
Evaluates the parameters on a stored procedure call to determine if they are input or output. Automatically set by DIALECT=MAINFRAME.
SQLCLRTRANS
Emulates mainframe behavior by substituting SQL Server savepoint operations for COMMIT and ROLLBACK when building both client applications and stored procedures. Uncommited work is rolled back when a stored procedure returns to the calling application unless the stored procedure was built with SPCOMMITONRETURN. Database locks are not released until the calling application performs a COMMIT or a ROLLBACK.
Note: If the client application is written in a language other than COBOL or PL/I, then it should also execute the SQL Server statement save transaction MF__SAVEPOINT at the start of every transaction (i.e., after every COMMIT or ROLLBACK statement) and when turning AUTOCOMMIT mode off.

Properties:

Default: None

Dependencies:

DIALECT=MAINFRAME automatically sets CHECKCALLPARAMS.

Scope:

Used at compile time: Yes
Behavior at run time: Source file

See Scope - HCOSS SQL Compiler Directive Options for more information.

Comment:

Separate each instance of OPTION with a space.

Example:

SQL(OPTION=CHECKCALLPARAMS)
Previous Topic Next topic Print topic