Re: DB Pager maxpages algorithm and lastpagefrom variable
| From: | Richard Wall | Date: | Wed, 24 Jul 2002 14:30:31 +0000 |
| Subject: | Re: DB Pager maxpages algorithm and lastpagefrom variable | ||
| References: | 1 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-7942@lists.php.net to get a copy of this message | ||
On 24/07/2002 13:24, Tomas V.V.Cox wrote:
What do DB_Pager users think on using that way instead of the Google way? Google is a little bit strange because the first time you get half the amount of pages and can confuse a little developers who wants a constant number. I myself preffer to set 10 pages and get 10 pages instead of 5 the first time :-)I prefer it this way *but* can't say I've tested it very thoroughly. Certainly I'd like to see the lastpagefrom included in DB_Pager. There's [lastpage], but that just seems to hold the total number of pages. On a slightly different note, has anyone noticed the FOUND_ROWS() function in MySQL 4... http://www.mysql.com/doc/M/i/Miscellaneous_functions.html (see bottom of page) Wondered if it might be a faster alternative to running a duplicate count(*) select query to get the num_rows. Also I wonder if it could somehow be done automatically by the limitQuery() method of PEAR::DB. Just a thought. -RichardW.