Skip to content
Advertisement

find the max for each value in SQL

i have tables like this

table 1

table 2

i want to get the max value for each element in table1 from table2 and the different parameter so the expecited tabel should be like this

Advertisement

Answer

You can try to compute all the maximums:

and then join them with the original Table2, e.g.

User contributions licensed under: CC BY-SA
10 People found this is helpful
Advertisement