note 64354 modified in function.mysqli-affected-rows by danbrown

From: Date: Fri, 28 Nov 2008 22:10:20 +0000
Subject: note 64354 modified in function.mysqli-affected-rows by danbrown
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-147309@lists.php.net to get a copy of this message
mysqli_affected_rows will return 0 if you run a UPDATE command with the same variables that already exist Here is a example db row from 'test' table ---------- id = 1 name = test mysqli_query($db,"UPDATE test SET name='test' WHERE id='1'"); $i=mysqli_affected_rows($db); $i Will Be Zero Or False --was-- mysqli_affected_rows will return 0 if you run a UPDATE command with the same variables that already exist Here is a example db row from 'test' table ---------- id = 1 name = test mysqli_query($db,"UPDATE test SET name='test' WHERE id='1'"); $i=mysqli_affected_rows($db); $i Will Be Zero Or False http://php.net/manual/en/function.mysqli-affected-rows.php

« previous php.notes (#147309) next »