Search the MySQL manual:

D.4.23 Changes in release 3.23.36 (27 Mar 2001)

User Comments

Posted by Mike Wexler on Monday June 17 2002, @7:39pm[Delete] [Edit]

The documentation on $sth->{rows} should talk
about the difference between rows matched and
rows changed.

For example

UPDATE foo SET bar=1 WHERE uniqueKey=1

Could set rows to 0 or 1 even if there was
exactly one record with uniqueKey=1 if the field
bar was already 1 $sth->{rows} would be zero
otherwise $sth->{rows} would be 1. Also a pointer
to how to get the other piece of information
(rows matched) would be nice.

Posted by Begrudged Biker Mouse on Monday June 17 2002, @7:39pm[Delete] [Edit]

Some of the field names listed there seem to be incorrectly cased. For example, using the current DBI::mysql, after a $sth=$dbh->prepare("LISTFIELDS users"); $sth->execute();, $sth->{TYPE} is set (as an ARRAYREF of types) but not $sth->{type}. Readers should probably consult the DBI docs if some fields turn up undef when typed in the cas mentioned here.

Add your own comment.