[prev in list] [next in list] [prev in thread] [next in thread] 

List:       msql-mysql-modules
Subject:    =?iso-8859-8?B?+vnl4eQ6IFJlOiBEQkQgMi45MDAyIGFuZCBkb2N1bWVudGF0?=
From:       nitzan shaked <calius () netvision ! net ! il>
Date:       2005-09-14 23:08:24
Message-ID: 494b501723b.4328d798 () netvision ! net ! il
[Download RAW message or body]

Rudy, Paul

Thanks for your answers. At least now I know this is the intended behavior and I feel \
better in relying on this.

Best regards,
Nitzan

----- הודעה מקורית -----
מאת: Rudy Lippan <rlippan@remotelinux.com>
תאריך: יום ד', ספטמבר 14, 2005 16:55
נושא: Re: DBD 2.9002 and documentation

> 
> 
> On Wed, 14 Sep 2005, nitzan shaked wrote:
> 
> > DBD 2.9002 changed the behavior of returned value from do(): it 
> now returns the number of *matched*
> > rows by default, and not the number of actually-changed rows. 
> This is documented in the changelog.
> > 
> > However, the DBI documentation states the value returned is the 
> number of affected rows (not
> > matched rows), and even still claims (under the "MySQL 
> features") that you can "change this using
> > a connection-string parameter".
> > 
> > This suggests to me that the documentation is wrong: it 
> acknowledges that both options exist, and
> > that claims the default is something which it's not.
> > 
> 
> The docs are wrong. I probably forgot to update them when I made 
> the change.
> Mea culpa, mea culpa....
> 
> > The question is also what happens in the C (and other) API: is 
> this the default or not? Is the default
> > *different* between APIs?
> > 
> > In short, is this:
> > 1) A documentation error, and all API's are aligned, or:
> > 2) A DBD-specific error, which should conform to some default 
> but doesn't.
> > 
> 
> Neither :).  It is a documentation error, and the documentation 
> should 
> read that rows() (and do()) returns the number of matched rows by 
> default. The
> C API defaults to the number of changed rows, so if you want the C 
> API 
> behaviour, you have to pass  "mysql_found_rows=0" to connect.
> 
> -r
> 


-- 
MySQL Perl Mailing List
For list archives: http://lists.mysql.com/perl
To unsubscribe:    http://lists.mysql.com/perl?unsub=msql-mysql-modules@progressive-comp.com



[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic