Re: Number of Lines in Table.

From: Date: Wed, 03 Sep 2014 05:22:04 +0000
Subject: Re: Number of Lines in Table.
References: 1 2 3 4  Groups: php.db 
Request: Send a blank email to php-db+get-48918@lists.php.net to get a copy of this message
On Sep 3, 2014, at 12:13 AM, Karl DeSaulniers <karl@designdrumm.com> wrote: >> >> >>> Dear List - >>> >>> This works: >>> >>> mysql> describe Purchases; >>> +-------+-------------+------+-----+---------+----------------+ >>> | Field | Type | Null | Key | Default | Extra | >>> +-------+-------------+------+-----+---------+----------------+ >>> | indx | smallint(6) | NO | PRI | NULL | auto_increment | >>> | manf | varchar(20) | YES | | NULL | | >>> | itm | varchar(50) | YES | | NULL | | >>> | prc | float | YES | | NULL | | >>> +-------+-------------+------+-----+---------+----------------+ >>> 4 rows in set (0.00 sec) >>> >>> What is my error? >>> >>> TIA >>> >>> Ethan Just for a little redemption.. :) I think this is what your looking for Ethan. http://stackoverflow.com/questions/5060366/mysql-fastest-way-to-count-number-of-rows SELECT SQL_CALC_FOUND_ROWS [itm] FROM Purchases LIMIT 50 OFFSET 0; SELECT FOUND_ROWS(); It says that FOUND_ROWS() has to be called immediately after the data selecting query. HTH, Best, Karl DeSaulniers Design Drumm http://designdrumm.com

« previous php.db (#48918) next »