Q&A for scientists using computers to solve scientific problems
DECLARE @UserId int = ##UserId## SELECT Count(*) AS ClassCount, Class FROM Badges WHERE UserId = @UserId GROUP BY Class ORDER BY Class DESC