Click or drag to resize

SQLSelect.PreExecute Method (Typed)

X#
Return the SQL command that is generated by X#.

Namespace:  XSharp.VO.SDK
Assembly:  XSharp.VOSQLClasses (in XSharp.VOSQLClasses.dll) Version: 2.21
Syntax
 VIRTUAL METHOD PreExecute(
	cSQLString AS STRING
) AS STRING
Request Example View Source

Parameters

cSQLString
Type: String
A string containing the SQL statement which will be passed to the SQL driver.

Return Value

Type: String
A possibly updated SQL string that will be passed to the SQL driver.
Remarks
This method is a callback method that is passed to the SQL command generated by X# for the purpose of inspection and optional modification, immediately prior to the command being passed to ODBC. It must return SQL statement text.
Examples
The following example demonstrates the use of the SQLSelect:PreExecute() method:
X#
1METHOD PreExecute(cSQLString) CLASS SubclassOfSQLSelect
2? sSQLString    //View all the SQL can modify it here, too
3RETURN cSQLString
See Also