summaryrefslogtreecommitdiff
path: root/ext/mysqlnd/mysqlnd.c
diff options
context:
space:
mode:
authorAndrey Hristov <andrey@php.net>2010-12-16 12:56:19 +0000
committerAndrey Hristov <andrey@php.net>2010-12-16 12:56:19 +0000
commit17b833604706cd187e4f3b4aeffa003adbeaf1dc (patch)
treee016d47fd1278c04b2d428d772cc96df17832cec /ext/mysqlnd/mysqlnd.c
parent4e08abeeadade8cdcd48d3c5a345948d98af0882 (diff)
downloadphp-git-17b833604706cd187e4f3b4aeffa003adbeaf1dc.tar.gz
fix a small bug about affected_rows in the text protocol
Diffstat (limited to 'ext/mysqlnd/mysqlnd.c')
-rw-r--r--ext/mysqlnd/mysqlnd.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/ext/mysqlnd/mysqlnd.c b/ext/mysqlnd/mysqlnd.c
index d4ccd00346..1d9ad8ddf8 100644
--- a/ext/mysqlnd/mysqlnd.c
+++ b/ext/mysqlnd/mysqlnd.c
@@ -1812,6 +1812,9 @@ MYSQLND_METHOD(mysqlnd_conn, next_result)(MYSQLND * const conn TSRMLS_DC)
DBG_INF_FMT("Error from the server : (%u) %s", conn->error_info.error_no, conn->error_info.error);
}
}
+ if (ret == PASS && conn->last_query_type == QUERY_UPSERT && conn->upsert_status.affected_rows) {
+ MYSQLND_INC_CONN_STATISTIC_W_VALUE(conn->stats, STAT_ROWS_AFFECTED_NORMAL, conn->upsert_status.affected_rows);
+ }
DBG_RETURN(ret);
}