php - Getting the number of affected rows including those not changed -
i doing statement this:
update tbl set x = 1 y = 2
and using rowcount
pdo whether or not row changed (y
unique, either none or 1 row updated). isn't need though, since, using previous example, if x
already 1, rowcount()
0 since no row changed previous value. need know whether row matched where
clause.
is there way without doing query?
it turns out pdo has thing: pdo::mysql_attr_found_rows
.
Comments
Post a Comment