
February 18th, 2000, 04:15 PM
|
|
Junior Member
|
|
Join Date: Feb 2000
Location: The Netherlands
Posts: 3
Time spent in forums: < 1 sec
Reputation Power: 0
|
|
|
Beste Martijn,
there is perhaps a different solution, I'm not sure you like it. URL
But is not difficult to find the next/prev id using a new query.
For example, if you want to find the previous id, simply execute following query:
SELECT max(id) FROM $table WHERE (id<$id)
The result is 67 ($id=75 as in your example), and is the id of the previous record.
For the next id, the query is:
SELECT min(id) FROM $table WHERE (id>$id)
With regards,
Roald
|