Hi,
Does anybody know how to find the highest Value in a column and return all data related to that highest value?
I have a table called Details:
Name
Age
Gender
Address1
PostCode
Country
I know how to return the highest value in a column..
But I need it to show all columns relating to the highest Age. I've tried the following but its showing an error message "You tried to execute a query that does not include the specified expression 'Name, Gender etc'as part of an aggregate function"
Does anybody have any idea's,
many thanks in advance
Does anybody know how to find the highest Value in a column and return all data related to that highest value?
I have a table called Details:
Name
Age
Gender
Address1
PostCode
Country
I know how to return the highest value in a column..
Code:
SELECT Max(Age) As Age From Details;
But I need it to show all columns relating to the highest Age. I've tried the following but its showing an error message "You tried to execute a query that does not include the specified expression 'Name, Gender etc'as part of an aggregate function"
Code:
SELECT Name, Max(Age) As Age, Gender, Address1, Postcode, Country From Details;
many thanks in advance