SQL Server syntax - I have this table:
C1 - C2 - C3
--------------
2 - AA - 10
2 - AA - 20
3 - AA - 15
3 - AA - 16
3 - AA - 56
1 - BB - 54
2 - BB - 53
2 - BB - 89
I need a query that will return this result:
C1 - C2 - C3
--------------
3 - AA - 15
3 - AA - 16
3 - AA - 56
2 - BB - 53
2 - BB - 89
So it should return only rows with maximum value of C1 over C2.
How can I do that ?