0 votes
1 view
in SQL by (30.7k points)

Can anyone tell me how to find max salary in SQL without using max function?

1 Answer

0 votes
by (72.4k points)

For SQL Server, here is the syntax to find the maximum salary of the employee table without using MAX () function:

SELECT TOP 1 Salary

FROM Employee_Table

ORDER BY Salary DESC

For SQL Server, here is the syntax to find the maximum salary of the employee table without using MAX () function:

SELECT Salary

FROM Employee_Table

ORDER BY Salary DESC

LIMIT 1

I suggest this SQL Training course by Intellipaat to learn SQL and writing complex SQL queries.

Related questions

0 votes
1 answer
asked Apr 21 in SQL by Sudhir_1997 (30.7k points)
0 votes
1 answer
asked Apr 20 in SQL by Sudhir_1997 (30.7k points)
0 votes
1 answer
asked Apr 20 in SQL by Sudhir_1997 (30.7k points)
0 votes
1 answer
asked Apr 26 in SQL by Sudhir_1997 (30.7k points)
Welcome to Intellipaat Community. Get your technical queries answered by top developers !


Categories

...