I have a need to retrieve a subset of records as follows:

Database structure:
Field0    Integer    Autonumber
Field1    Integer    Unique
Field2    Integer    not unique

where the starting record would be selected by Field1 (an indexed field of
unique values).

The ending record required would be the first succeeding record where the
value of Field2 is equal to the value of Field2 in the 'starting' record.
Field2 is NOT unique, and is not in any particular order.

The result would be ordered by Field0 (the autonumber field)

Is this possible?

TIA,
Charlie

MySQL Query

---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to