Google 表格:QUERY return 单列
Google Sheets: QUERY to return a single column
我正在使用此查询来查找数据列中最受欢迎的条目 - 如何将查询结果限制为仅数据条目,而不返回聚合列:
=QUERY(G2:G14,"select G, count(G) where G is not null group by G order by count(G) DESC label G 'Product'",-1)
尝试:
=INDEX(QUERY(G2:G14,
"select G, count(G)
where G is not null
group by G
order by count(G) desc
label G 'Product'", -1),, 1)
我正在使用此查询来查找数据列中最受欢迎的条目 - 如何将查询结果限制为仅数据条目,而不返回聚合列:
=QUERY(G2:G14,"select G, count(G) where G is not null group by G order by count(G) DESC label G 'Product'",-1)
尝试:
=INDEX(QUERY(G2:G14,
"select G, count(G)
where G is not null
group by G
order by count(G) desc
label G 'Product'", -1),, 1)