Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/google-apps-script/5.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/5/google-sheets/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/angularjs/20.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Google apps script 是否可以查询行中的范围不为空_Google Apps Script_Google Sheets - Fatal编程技术网

Google apps script 是否可以查询行中的范围不为空

Google apps script 是否可以查询行中的范围不为空,google-apps-script,google-sheets,Google Apps Script,Google Sheets,我试图查询一个谷歌表格,其中一行中的单元格范围不为空。以下是我的数据示例: 我正在使用我的公式来显示在列E、F、G或H中填充了任何内容的行,因此使用上面的示例数据,我希望查询返回以下内容: 下面的公式只返回标题,因为它要查看每个单元格是否为空 =Query(A1:H6,"Select * where E is not null and F is not null and G is not null and H is not null",1) 有解决方法吗?让我们用或代替和 =Query(A

我试图查询一个谷歌表格,其中一行中的单元格范围不为空。以下是我的数据示例:

我正在使用我的公式来显示在列E、F、G或H中填充了任何内容的行,因此使用上面的示例数据,我希望查询返回以下内容:

下面的公式只返回标题,因为它要查看每个单元格是否为空

=Query(A1:H6,"Select * where E is not null and F is not null and G is not null and H is not null",1)

有解决方法吗?

让我们用
代替

=Query(A1:H6,"Select * where E is not null or F is not null or G is not null or H is not null",1)

让我们用
代替

=Query(A1:H6,"Select * where E is not null or F is not null or G is not null or H is not null",1)

那奏效了,谢谢你。我最初确实尝试过,但我在查询中有另一个where语句,我将其置于“或”之后,现在意识到我应该将“和”置于所有“或非空”语句之前。您可以添加
()
where。。。和(…或…或…
来分隔有效的条件,谢谢。我最初确实尝试过,但我在查询中有另一个where语句,我将其置于“或”之后,现在意识到我应该将“和”置于所有“或非空”语句之前。您可以添加
()
where。。。和(…或…或…)
来分隔条件