# odbc_exec

(PHP 4, PHP 5, PHP 7)

odbc_exec — Prepare and execute an SQL statement

### 说明

odbc_exec ( resource `$connection_id` , string `$query_string` [, int `$flags` ] ) : resource

Sends an SQL statement to the database server.

### 参数

`connection_id`

  ODBC 连接标识符，详见 odbc_connect()。

`query_string`

  The SQL statement.

`flags`

  This parameter is currently not used.

### 返回值

Returns an ODBC result identifier if the SQL command was executed successfully, or `FALSE` on error.

### 参见

- odbc_prepare() - Prepares a statement for execution
- odbc_execute() - Execute a prepared statement