Below is my table structure after joinning two tables in an SQL View. How the view is already grouped by name but i want to add a column showing how many status '5' rows there are for each group. I cannot figure out how to do this. I have to be missing something. I know it has be in the Select Statement but i am having a hard time with the syntax.
Id | Status | Name
1 5 John
2 5 John
3 9 Susan
4 5 Susan
I would like my results to show
Name | Status 5
John 2
Susan 1
Thanks in advance.
Id | Status | Name
1 5 John
2 5 John
3 9 Susan
4 5 Susan
I would like my results to show
Name | Status 5
John 2
Susan 1
Thanks in advance.