1:
sSQLString = "select data_length, count(*) from (SELECT CASE WHEN datalength(Request) < 400 THEN 'Up to 400' ELSE '> 400' END as data_length FROM dbo.qryStatsRequests WHERE Request IS NOT NULL ) a GROUP BY a.data_length"