select sum(money) money from dingdong.detailed
where DATE_FORMAT(FROM_UNIXTIME( time, '%Y%m%d' ),'%Y')=DATE_FORMAT(now(),'%Y')
select sum(money) count from dingdong.detailed
where DATE_FORMAT(FROM_UNIXTIME( time, '%Y%m%d' ),'%Y%u')=DATE_FORMAT(now(),'%Y%u')
select sum(money) money from dingdong.detailed
where DATE_FORMAT(FROM_UNIXTIME( time, '%Y%m%d' ),'%Y%m%d')=DATE_FORMAT(now(),'%Y%m%d')
网友评论