|
cubrid_execute(PECL CUBRID >= 8.3.0) cubrid_execute — Execute a prepared SQL statement Описание
resource cubrid_execute
( resource $conn_identifier
, string $sql
[, int $option
] )
bool cubrid_execute
( resource $request_identifier
[, int $option
] )
The cubrid_execute() function is used to execute the given SQL statement. It executes the query by using conn_identifier and SQL, and then returns the request identifier created. It is used for simple execution of query, where the parameter binding is not needed. In addition, the cubrid_execute() function is used to execute the prepared statement by means of cubrid_prepare() and cubrid_bind(). At this time, you need to specify arguments of request_identifier and option. The option is used to determine whether to get OID after query execution and whether to execute the query in synchronous or asynchronous mode. CUBRID_INCLUDE_OID and CUBRID_ASYNC (or CUBRID_EXEC_QUERY_ALL if you want to execute multiple SQL statements) can be specified by using a bitwise OR operator. If not specified, neither of them isselected. If the flag CUBRID_EXEC_QUERY_ALL is set, a synchronous mode (sync_mode) is used to retrieve query results, and in such cases the following rules are applied:
If the first argument is request_identifier to execute the cubrid_prepare() function, you can specify an option, CUBRID_ASYNC only. Список параметров
Возвращаемые значенияRequest identifier, when process is successful and first param is conn_identifier; TRUE, when process is successful and first argument is request_identifier. FALSE, when process is unsuccessful. Список изменений
ПримерыПример #1 cubrid_execute() example
<?php Результат выполнения данного примера: athlete host_year score unit Phelps Michael 2004 51.25 time Смотрите также
|
|||||