- If you are ever unsure what to put inside a
COUNT()
aggregation, you can doCOUNT(1)
to count the rows in each group. Most people find it especially readable, because we know it's not focusing on other columns. It also scans less data than if supplied column names (making it faster and using less of your data access quota). - 如果不知道判定什么,可以用
COUNT(1)
来count each group
转载于:https://www.cnblogs.com/bamboozone/p/10645288.html