select f_stataddress,sum(f_stataddress_num) from
(selelct convert(varchar(2),f_stataddress) f_stataddress,f_stataddress_num from T1 ) AS T
group by f_stataddress
您的语句有错误啊
@yujinchao: 哪错
用这个吧
select f_state_address,sum(f_addres_num) from (select left(f_state_address,2) f_state_address, f_addres_num from T1 ) AS T group by f_state_address
楼上的第二行 select 写错了,并且convert函数 是日期转换函数吧?!