繁体   English   中英

我想在 arrayformula 中使用这个查询

[英]I want to use this query in an arrayformula

=iferror(QUERY(importorders!A:H,“Select count(A) where C = ‘Thailand Tour’ and month(H) = “&MONTH(A3)-1&“and year(H) = “&year(A3)&” label count(A) ‘’“,1),0)

基本上只是计算我每个月有多少订单。

https://docs.google.com/spreadsheets/d/1Of6cdFYaOzCFwPdZ4ABItD6dghMjHhafRWmDJWaznbg/edit#gid=711075203

在此处输入图片说明

B3单元格中使用它:

=ARRAYFORMULA(IFNA(VLOOKUP(A3:A, QUERY({importorders!A2:C, 
 EOMONTH(importorders!H2:H, -1)+1},
 "select Col4,count(Col1) 
  where Col3 = 'Thailand Tour' 
    and Col4 is not null 
  group by Col4
  label count(Col1)''", 0), 2, 0), 0))

0

尝试

=query(A2:H,"select Year(H), Month(H)+1, C, Count(H) where C is not null and C like 'Thailand%' group by Year(H), Month(H)+1,C label C'Tour',Year(H)'Year',Month(H)+1'Month'")

应用于数据透视表的此数据可能会提供更易于理解的分析。


报告摘录

报告摘录

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM