I have the following db diagram :
I want to find the decade (for example 1990 to 2000) that has the most number of movies. Actually it only deals with "
select substring(cast([year] as varchar), 1, 3) as Decade, Count(1) [Count] from Movies group by substring(cast([year] as varchar), 1, 3) order by 2 desc