php mysql_affected_rows function


php mysql_affected_rows function

mysql_affected_rows Get the number of affected rows by the last INSERT, UPDATE, REPLACE or DELETE query.

$link = mysql_connect(‘localhost’, ‘username’, ‘password’);
if (!$link) {
die(‘Could not connect: ‘ . mysql_error());

// This will return the number of records deleted
mysql_query(‘DELETE FROM table WHERE fldid < 100’);
print “Records Deleted By Above Query: “. mysql_affected_rows();
// Output will be like this : Records Deleted By Above Query: 10



  1. It tells you what to do if you become anxious in social scenarios.

  2. Wonderful work! That is the type of info that should be shared around the web.

    Disgrace on the search engines for now not positioning this put up upper!
    Come on over and seek advice from my website . Thanks

RSS feed for comments on this post · TrackBack URI

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: