Описание тега mysqli-multi-query

Use this tag in case of multi-query execution in mysqli. mysqli_multi_query() executes one or multiple queries which are concatenated by a semicolon and returns TRUE on success or FALSE on failures.

mysqli_multi_query() executes one or multiple queries which are concatenated by a semicolon and returns TRUE on success or FALSE on failures. This can be performed either as procedural style or OOP style(see usage section).

Usage

Object oriented style

bool mysqli::multi_query ( string $query )

Procedural style

bool mysqli_multi_query ( mysqli $link , string $query )
  • bool is the return value type and depends on the passed $variable.
  • mysqli:: refers to the mysqli object initialised using stmt_init() or mysqli_prepare() call.
  • $query is the query, as a string. Data inside the query should be properly escaped.

Miscellaneous

  • mysqli_query() - Performs a query on the database
  • mysqli_use_result() - Initiate a result set retrieval
  • mysqli_store_result() - Transfers a result set from the last query
  • mysqli_next_result() - Prepare next result from multi_query
  • mysqli_more_results() - Check if there are any more query results from a multi query

Related tag