From 4b5c276559d236490ea05c733c8f784c1d50208b Mon Sep 17 00:00:00 2001 From: Markus Fischer Date: Fri, 6 Sep 2002 13:02:32 +0000 Subject: [PATCH] - Document the "changes database and not back" behaviour. - Incooperate user comment about insert/select/delete queries from ceo@l-i-e.com git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@94890 c90b9560-bf6c-de11-be94-00142212c4b1 --- reference/mysql/functions/mysql-db-query.xml | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/reference/mysql/functions/mysql-db-query.xml b/reference/mysql/functions/mysql-db-query.xml index c21ff3912e..8072cdd647 100644 --- a/reference/mysql/functions/mysql-db-query.xml +++ b/reference/mysql/functions/mysql-db-query.xml @@ -1,5 +1,5 @@ - + @@ -18,7 +18,9 @@ Returns a positive MySQL result resource to the query result, - or &false; on error. + or &false; on error. The function also returns &true;/&false; for + INSERT/UPDATE/DELETE + queries to indicate success/failure. mysql_db_query selects a database and @@ -28,6 +30,15 @@ as if mysql_connect was called with no arguments. + + Be aware that this function does NOT + switch back to the database you were connected before. In other words, + you can't use this function to temporarily run a + sql query on another database, you would have to manually switch back. + Users are strongly encouraged to use the + database.table syntax in their sql queries instead of + this function. + See also mysql_connect and mysql_query.