I have a table e.g.
Artist Title Song Key Easytosing
A Title A A No
A Title A B Yes
A Title A F Yes
B Title B A Yes
C Title C F# No
I want to return each individual song that is tagged 'easytosing' but also show how many versions there are of that song a) easytosing b) total e.g. Ideal results would be:
Artist Title How_many_tot How_many_easy
A Title A 3 2
B Title B 1 1
I can show how many are easy to sing using:
SELECT *, count(*) as How_many_easy from tracks
where easytosing='Yes'
group by artist,title
order by artist asc
Is there a way I can show both so the query only selects the easytosing but counts all?