Imagine the following lines in my MySQL database:
I want a query that displays the name and age of the person who is the oldest in the table, so I did this query :
SELECT nome, MAX(idade)
from pessoas;
But it does not return the name correctly.
I need a solution that conditions the age name returned by the MAX
command, did not want a subquery that compares if the age with the MAX(idade)
of another query. Is there what I need?