Re: mssql_fetch_row();
| From: | Jim Lucas | Date: | Fri, 11 Apr 2003 16:25:38 +0000 |
| Subject: | Re: mssql_fetch_row(); | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-143534@lists.php.net to get a copy of this message | ||
Check out the mssql_data_seek() function
This will do the job
Jim
----- Original Message -----
From: "Poon, Kelvin (Infomart)" <kpoon@infomart.ca>
To: <php-general@lists.php.net>
Sent: Friday, April 11, 2003 7:16 AM
Subject: [PHP] mssql_fetch_row();
> Hi,
>
> In my script, I take our the first 20 entries of my SQL table like this:
>
> $query = "SELECT * FROM updateHistory WHERE AIX = '$search' ORDER BY VAX";
> $result = mssql_query($query);
>
> for ($i = $start; $i < mssql_num_rows($result); ++$i)
> {
> $updateHistory = mssql_fetch_row($result);
>
> // code here....
>
>
> $numRecord+=1;
> if ($numRecord==20) {
> break;
> }
> }
>
> THis code successfully processing the first 20 entries of the data I took
> out from the query. My question is, how do I take out the 21st to the
40th
> entries?...or 41st to 60th entries?..basically I want it to function so
that
> it can process the 'next 20' each time.
>
> Please advise, thanks
>
> Kelvin
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>