Can you write a SQL command for helping me in these two columns?
for example…..these two columns
a1 a2
______ ______
1 1
2 1
1 2
2 3
3 1
3 2
4 1
4 2
I want the output:
a1 a1
1 2
2 3
3 2
4 2
I’m guessing, based on your example, that you want the second column to be the maximum a2 value for the corresponding a1 value.
Then you want: