Subject | Re: [firebird-php] ibase_num_rows instead of count(*) |
---|---|
Author | Lester Caine |
Post date | 2004-09-07T18:22:47Z |
Almond wrote:
number of rows affected in PHP5 !
From the manual ...
Note: In PHP 5.0.0 and up, this function returns the number of rows
affected by the query (if > 0 and applicable to the statement type). A
query that succeeded, but did not affect any rows (e.g. an UPDATE of a
non-existent record) will return TRUE.
That applies to updates and is also returned as ibase_affected_rows, but
if using SELECT, then it depends if you download all the rows, in which
case you just read the count of number of records downloaded.
--
Lester Caine
-----------------------------
L.S.Caine Electronic Services
> I do know that kind of trick, but it only return the total record count. ITHAT is a different problem. There has been some work on returning the
> want to show the user the no. of record their query returns :(.
number of rows affected in PHP5 !
From the manual ...
Note: In PHP 5.0.0 and up, this function returns the number of rows
affected by the query (if > 0 and applicable to the statement type). A
query that succeeded, but did not affect any rows (e.g. an UPDATE of a
non-existent record) will return TRUE.
That applies to updates and is also returned as ibase_affected_rows, but
if using SELECT, then it depends if you download all the rows, in which
case you just read the count of number of records downloaded.
--
Lester Caine
-----------------------------
L.S.Caine Electronic Services