[prev in list] [next in list] [prev in thread] [next in thread]
List: pear-dev
Subject: Re: [PEAR-DEV] PEAR DB - some suggested improvements
From: 203.106.49.72
Date: 2001-10-28 9:20:57
[Download RAW message or body]
Hi Tomas,
Tomas V.V.Cox <cox@idecnet.com> wrote in message
news:3BDB3FDA.9738C273@idecnet.com...
> John Lim wrote:
> >
> > Hello,
> >
> > While reviewing PEAR DB for a book I'm writing,
>
> Oh yes? nice, please advice us when it get published :-)
>
Sometime next year. Am working with Andrei Z. and a few other writers.
>
> In Pear DB we offer two kind of error messages, both accesible from the
> Pear Error object:
My mistake - i misread some of the implementation details in the source
code.
Of course you are right.
> > 2. The oci8 driver attempts to return the numRows() by
> > changing the select statement to a select count(*). This
> > will only work in a single-user or read-only environment.
> > Better to accept defeat and just return -1.
>
> This is not the default behavoir of the driver and by default it will
> return a "not capable" error message. But if you really needed it you
> can use it any way. What's the problem of the count() stuff?
>
The count() stuff is not reliable, and is misleading. Eg. you
SELECT count(*) FROM messages
then 2 users post new messages before you retrieve the messages. Your
count(*) will be wrong. Of course the PEAR DB programmer has to enable
portability on, so perhaps that is his problem...
Bye, John
--
PEAR Development Mailing List (http://pear.php.net/)
To unsubscribe, e-mail: pear-dev-unsubscribe@lists.php.net
For additional commands, e-mail: pear-dev-help@lists.php.net
To contact the list administrators, e-mail: php-list-admin@lists.php.net
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic