note 51339 added to function.mysql-affected-rows

From: Date: Mon, 28 Mar 2005 06:56:44 +0000
Subject: note 51339 added to function.mysql-affected-rows
Groups: php.notes 
Request: Send a blank email to php-notes+get-87074@lists.php.net to get a copy of this message
In libmysql.c (MySql source), mysql_affected_rows() returns mysql->last_used_con->affected_rows, while mysql_store_result() sets the field to the number of rows: mysql->affected_rows= result->row_count= result->data->rows. mysql_store_result() reads the entire result of a query to the client, after which mysql_fetch_row() can be called to fetch rows from the result set. So, mysql_affected_rows() can be used to retrieve the number of rows returned by a SELECT. ---- Manual Page -- http://www.php.net/manual/en/function.mysql-affected-rows.php Edit -- http://master.php.net/manage/user-notes.php?action=edit+51339 Delete: added to the manual -- http://master.php.net/manage/user-notes.php?action=delete+51339&report=yes&reason=added+to+the+manual Delete: bad code -- http://master.php.net/manage/user-notes.php?action=delete+51339&report=yes&reason=bad+code Delete: spam -- http://master.php.net/manage/user-notes.php?action=delete+51339&report=yes&reason=spam Delete: useless -- http://master.php.net/manage/user-notes.php?action=delete+51339&report=yes&reason=useless Delete: other reasons -- http://master.php.net/manage/user-notes.php?action=delete+51339&report=yes Reject -- http://master.php.net/manage/user-notes.php?action=reject+51339&report=yes Search -- http://master.php.net/manage/user-notes.php

« previous php.notes (#87074) next »