[英]Google sheets queries with IF statments
I am trying to write this query for a while and have tried a few sites but not explain really how to use the IF statement.我尝试编写此查询已有一段时间,并尝试了几个站点,但并未真正解释如何使用 IF 语句。
So I have data in columns that are people scores for films所以我在列中有数据,这些数据是人们对电影的评分
Jim吉姆 | Jack杰克 | Fred弗雷德 | |
---|---|---|---|
Film 1电影 1 | 6 6个 | 6 6个 | 2 2个 |
Film 2电影 2 | 7 7 | 8 8个 | 5 5个 |
Film 3电影 3 | 3 3个 | 5 5个 | 8 8个 |
... ... |
for example and i want a query that when i select a cell with a name in it it will return the scores for that person (make top ten and scores by film genera / person etc.)例如,我想要一个查询,当我 select 一个有名字的单元格时,它将返回那个人的分数(进入前十名和电影属/人等的分数)
So I have this query I know the syntax is not correct I have tried many ways and cant get it to work.所以我有这个查询我知道语法不正确我已经尝试了很多方法但无法让它工作。 (E18 is the cell I with a pick list of the names) (E18 是带有名称选择列表的单元格 I)
=Query(Sheet1!A4:D,"select A & IF(E18=”Jim”, select B order by B desc Limit 10"")")
What I want to do is when I select a name then it returns the top 10 films for that user + the scores我想要做的是当我 select 一个名字然后它返回该用户的前 10 部电影 + 分数
Any help greatly received.收到任何帮助。
Thankyou谢谢
aaron亚伦
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.