sql 比例计算

select stationid, ltrim(cast(count(*)*100.0/(select count(*) from t_sys_user) as dec(18,2)))+'%' 

from t_sys_user group by stationid

posted @ 2017-04-06 10:31  熊大大-  阅读(952)  评论(0编辑  收藏  举报