standard.db.sql.ODBCExecuteQuery

ODBCExecuteQuery is available since version 1.0.

Prototype:

number ODBCExecuteQuery(string query[, number connectionID])

Parameters

query
the SQL query
connectionID
the ID identifying the connection as returned by ODBCDriverConnect or ODBCConnect. If this parameter is missing, this will affect the first connection created.

Description:

Create and executes a statement. The SQL query must not contain any bound parameters in order to successfully execute the query. For bounded parameters you must use the ODBCExecute function.

Also, after a query that provides results is successfully executed, you must call {ODBCBind} in order to be able to access the data in the result set (result set is the same as statement handle).

Return value:

Return handle of a statement containing the result of the executed query.