Try using code like this:
<?php
if( ! isset( $index ))
$index = 0;
$query = "SELECT * FROM table LIMIT $index,20";
$result = mysql_query( $query );
?>
This LIMIT clause tells the SQL server to return 20 rows, starting at row $index. Please note that rows start at 0, not 1.
http://www.mysql.com/doc/S/E/SELECT.html
Hope this helps!
-Rich