Subject RE: [firebird-support] Very slow SQL
Author Leyne, Sean

> I have the following SQL statement:
> select * from ClientINfo
> where Client_Id in (Select Max(Client_ID) from ClientInfo)
> where Client_ID is the primary key of ClientInfo.

If you are looking for the last record try:

select first 1 *
from ClientINfo
order by Client_ID desc


P.S. This is an extremely poor design.