I have the following result which i have got after using this query :
select SCHOOL_YEAR,COUNT(MUSIC) as ct,MUSIC from [table1]
group by SCHOOL_YEAR,MUSIC;
SCHOOL_YEAR ct MUSIC
2011 100 Piano
2011 50 Violin
2012 70 Piano
2012 150 Violin
I want it in the following format :
SCHOOL_YEAR Piano Violin
2011 100 50
2012 70 150
How can i achieve it ?