Private archive copy · Unofficial site · Content copyright belongs to Runoob Tutorial and the original authors · View Original

PHP mysqli_multi_query() Function

PHP mysqli_multi_query() Function

PHP MySQLi Reference Manual PHP MySQLi Reference Manual

Example

Execute multiple queries against the database:


Definition and Usage

The mysqli_multi_query() function executes one or more queries against the database. Multiple queries are separated by semicolons.


Syntax

mysqli_multi_query(

connection,query

)

;

Parameters Description
connection Required. Specifies the MySQL connection to use.
query Required. Specifies one or more queries, separated by semicolons.

Technical Details

Return Value: Returns FALSE if the first query fails.
PHP Version: 5+

PHP MySQLi Reference Manual PHP MySQLi Reference Manual