If you want to just select the id
use select max(id) from customer
.
If you want to select the entire row then use a query like this:
select c1.*
from customer c1, (select max(id) as max_id from customer )c2
where c1.id=c2.max_id
c2
is an alias for the new temporary table which contains max id
. Then its cross product is taken with customer table to get the entire row.
Here we are writing a query in the from clause, which can often be quite useful.