示例
GROUP BY 子句中可以使用SELECT 子句中定义别名
sql
SELECT DATE(add_time) AS addTime, COUNT(*) AS total
FROM user
GROUP BY addTime
ORDER BY addTime
GROUP BY 子句中可以使用SELECT 子句中定义别名
SELECT DATE(add_time) AS addTime, COUNT(*) AS total
FROM user
GROUP BY addTime
ORDER BY addTime