hi to all
Consider a table like this...
Term runs from 1 to 1024, consecutively, with each value of Term having Rank values from 1 to 10. K is 1 or 0.
I want to GROUP BY Term and K, but... I need to show the COUNT of each local grouping of 0 and 1.
The output would look like this, ORDERed BY TERM, FirstOfRank...
Thanks in anvance for any help
Vicky C
Consider a table like this...
Code:
[bold]
Term Rank K [/bold]
1 1 1
1 2 1
1 3 0
1 4 0
1 5 1
1 6 0
1 7 0
1 8 0
1 9 1
1 10 0
2 1 0
2 2 0
2 3 0
2 4 1
2 5 0
2 6 0
2 7 1
2 8 0
2 9 1
2 10 0
3 etc...
Term runs from 1 to 1024, consecutively, with each value of Term having Rank values from 1 to 10. K is 1 or 0.
I want to GROUP BY Term and K, but... I need to show the COUNT of each local grouping of 0 and 1.
The output would look like this, ORDERed BY TERM, FirstOfRank...
Code:
[bold] [u]
Term FirstOfRank K LocalGroupCount [/bold]
1 1 1 2
1 3 0 2
1 5 1 1
1 6 0 3
1 9 1 1
1 10 0 1
2 1 0 3
2 4 1 1
2 5 0 2
2 7 1 1
2 8 0 1
2 9 1 1
2 10 0 1
3 etc...
Thanks in anvance for any help
Vicky C