DATE_FORMAT(bv.priceDate, '%Y-%m-%d') as priceDate,
DATE_FORMAT(bv.priceDate, '%Y-%m-%d') as priceDate,
bv.costPrice as priced,
bv.costPrice as priced,
bv.insideCode,
bv.insideCode,
(select count(*) from base_vehicle bvv where bvv.insideCode = bv.insideCode and (bvv.vehicleStateValue = '库存' or bvv.vehicleStateValue = '调入')) as vehicleNum,
(select count(*) from base_vehicle bvv where bvv.insideCode = bv.insideCode and (bvv.vehicleStateValue = '库存' or
bvv.vehicleStateValue = '调入')) as vehicleNum,
(select datediff(now(),DATE_FORMAT(bv.priceDate,'%Y-%m-%d'))) as dayNum
(select datediff(now(),DATE_FORMAT(bv.priceDate,'%Y-%m-%d'))) as dayNum