Hi I am trying to get maximum ID from a table which has approx 1 million records. Please suggest me which on of these query will execute faster.
Option 1:
select top 1 SurveyUserResponseID from surveyuserresponse order by SurveyUserResponseID desc
Option 2:
select max(SurveyUserResponseID) from surveyuserresponse
as per actual execution plan both query took same time to execute.