If you do not have the index on this field, then you may use locate command, like:
locate for between(...)
locate for datetime>... and datetime <...
Otherwise:
set order to ...
set near on
?seek(...)
>Hi,
>I'd like to find a datetime field in a table which is the nearest to a certain given datetime. What functions can be used? And Any idea would be appreciated.
>
>Thanks
>
>Tamas Szigeti