[Solved] SQL Query to Transpose Column Counts to Row Counts

These type of queries are easier to make with an aim of GROUP BY, like this: Select case when profile.foo ~* ‘5.0.2195’ then ‘Win2k’ when profile.foo ~* ‘5.1.2600’ then ‘WinXP’ when profile.foo ~* ‘5.2.3790’ then ‘W2k3’ when (profile.foo ~* ‘6.0.6000’ or profile.foo ~* ‘6.0.6001’ or profile.foo ~* ‘6.0.6002’) then ‘Vista’ when (profile.foo ~* ‘6.1.7600’ or … Read more