按月份统计每个月的订单总金额SQL语句解析

一.SQL语句: select              IFNULL(sum(case month(createTime) when '1' then price else 0 end), 0) as 一月份,             IFNULL(sum(case month(createTime) when '2' then price else 0 end), 0) as 二月份,   
相关文章
相关标签/搜索