yzmEFF7y2982052(提问者)帆软里的呀,
select 总成本,设备数,总成本/设备数 平均成本 from (
select sum(b.costs/b.usagetime)总成本,count(equipmentid) 设备数
from Equipment a join EquipmentDetail b
on a.CompanyID=b.CompanyID
where company=\'${company}\')
yzmEFF7y2982052(提问者)select 总成本,设备数,总成本/设备数 平均成本 from ( select sum(b.costs/b.usagetime)总成本,count(equipmentid) 设备数 from Equipment a join EquipmentDetail b on a.CompanyID=b.CompanyID where company=\\\'${company}\\\')
我在b.costs*1.00 就出现小数啦