MySQLi
PHP Manual

mysqli::real_query

mysqli_real_query

(PHP 5)

mysqli::real_query -- mysqli_real_queryExecute an SQL query

说明

面向对象风格

bool mysqli::real_query ( string $query )

过程化风格

bool mysqli_real_query ( mysqli $link , string $query )

Executes a single query against the database whose result can then be retrieved or stored using the mysqli_store_result() or mysqli_use_result() functions.

In order to determine if a given query should return a result set or not, see mysqli_field_count().

参数

link

仅以过程化样式:由 mysqli_connect()mysqli_init() 返回的链接标识。

query

The query, as a string.

Data inside the query should be properly escaped.

返回值

成功时返回 TRUE, 或者在失败时返回 FALSE.

参见


MySQLi
PHP Manual