I am querying an sql db that is fairly large. Some queries return several thousand records.
I'm trying to make a 'next page' link that will return the next 100 records in a query so that only 100 display on each page.
I want to declare a $var as the MAX ID of any given query then when the 'Next page' button is clicked, the query will run again where $var = >100
I was thinking of putting a dowhile into:
  echo '<table class="table table-hover table-condensed table-striped">
        <tr><th>MY_ID</th><th>MT_TYPE</th>';
        foreach($result_head as $row_head) {
            foreach($row_head as $col_headers) {
                $col_heads_split = explode(",",$col_headers);
                foreach($col_heads_split as $col_head) {
                    echo '<th>'.$col_head.'</th>';
                        $maxid = SELECTMAX(MY_ID) FROM dbo.mydb
                        do {
                         $nextpage = *= $maxid
                         while $nextpage = >100
                         }
                }
            }
        }
    echo '</tr>';
So essentially running the same query 100 results at a time.
Thanks for your help!
