【问题标题】:Google Sheets query - Multiple "where" conditions with "group by" and "order by"谷歌表格查询 - 多个“where”条件与“group by”和“order by”
【发布时间】:2019-04-02 18:23:50
【问题描述】:

我正在尝试在 Google 表格查询公式中使用多个 where 条件(2 个条件)和“分组依据”和“排序依据”语句。

query(Sites!A:D,"select A,C,sum(D) 
    where B contains 'Google' 
    and sum(D) > 100 
    group by A,C 
    Order by sum(D) desc label sum(D) 'Total Impressions'")

上面是我尝试过的公式,但它给我一个#VALUE 错误!

语句的顺序有问题吗?

【问题讨论】:

    标签: google-sheets-query


    【解决方案1】:
    【解决方案2】:

    添加第二个应该工作的地方

    query(Sites!A:D,"select A,C,sum(D) 
        where B contains 'Google' 
        and where sum(D) > 100 
        group by A,C 
        order by sum(D) desc label sum(D) 'Total Impressions'")
    

    【讨论】:

      猜你喜欢
      • 2023-03-15
      • 2017-02-11
      • 1970-01-01
      • 2019-01-21
      • 1970-01-01
      • 2012-06-12
      • 2021-11-17
      • 1970-01-01
      • 2012-12-31
      相关资源
      最近更新 更多