从结果集中筛选解决办法

从结果集中筛选selectsum(total)fromselectcount(*)astotalfromtvistedgroupbyuserid用这句话查询时总是说

从结果集中筛选
select   sum(total)   from   select   count(*)   as   total   from   tvisted   group   by   userid

用这句话查询时总是说“在关键字   'select '   附近有语法错误。”不知道为什么




[解决办法]
select sum(total) from
(select count(*) as total from tvisted group by userid)a