Return affected rows for alter queries. Props BjornW. fixes #7215

git-svn-id: http://svn.automattic.com/wordpress/trunk@9204 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
ryan 2008-10-16 19:54:00 +00:00
parent c7f54da90b
commit c946b75953
1 changed files with 1 additions and 1 deletions

View File

@ -617,7 +617,7 @@ class wpdb {
return false;
}
if ( preg_match("/^\\s*(insert|delete|update|replace) /i",$query) ) {
if ( preg_match("/^\\s*(insert|delete|update|replace|alter) /i",$query) ) {
$this->rows_affected = mysql_affected_rows($this->dbh);
// Take note of the insert_id
if ( preg_match("/^\\s*(insert|replace) /i",$query) ) {