10 records per page

10 records per page

am 03.05.2006 06:48:16 von webmechanic

I am able to retrieve records from database and would like to break
down to 10 records per page. I would like to have "total pages" count,
"previous[whatever number]", "next[whatever number]".

Re: 10 records per page

am 03.05.2006 09:53:39 von lists.niekas

For limiting the returned results by a query try using the LIMIT (
"SELECT .. FROM .. LIMIT 10,10" - will return 10 rows from the query
starting from 10th row).

In order to have total count of rows you will have to use separate
query like: "SELECT COUNT(*) AS count FROM ... WHERE ..."

--
Niekas [ more mySQL help at http://forums.niekas.com ]

Re: 10 records per page

am 03.05.2006 17:54:27 von cmgmyr

Try looking at
paging...http://www.php-mysql-tutorial.com/php-mysql-paging. php

Re: 10 records per page

am 03.05.2006 21:18:23 von tihu

Chris - syracusecs.com wrote:
> Try looking at
> paging...http://www.php-mysql-tutorial.com/php-mysql-paging. php

In case you are not using
mysql....http://troels.arvin.dk/db/rdbms/#select-limit-offse t