0

我有一个长长的查询函数到三个单元格的 if 函数(下面是一个包含两个单元格的简单版本):

=IF(B2="All";Query(Sheet!1:100000;"select B,C,F"); Query(Sheet!1:100000;"select B,C,F where C contains """&B2&""" and B contains """&D2&"""  ")

B2 和 D2 是我有填写查询的项目列表的单元格

现在我想要:在查询的开头插入一个空白值。我可以用:

if (isblank(B2);iferror(1/0)

但不与两个或更多细胞一起使用。

=if (isblank(B2);iferror(1/0), if(isblank(D2);iferror(1/0),,IF(B2="All";Query(Sheet1!1:100000;"select B,C,F"); Query(Sheet1!1:100000;"select B,C,F, where C contains """&B2&""" and B contains """&D2&""" "))))

此外,我想学习使用不同的条件(使用 OR 和 AND)。

你能帮助我吗?

4

1 回答 1

0

我也不知道你想要什么,但我猜它可能是:

=IF(or(ISBLANK(B2),isblank(D2)),iferror(1/0),if(B2="All",Query(Sheet4!1:100000,"select B,C,F"), Query(Sheet4!1:100000,"select B,C,F where C contains """&B2&""" and B contains """&D2&""" ",C9)))
于 2014-07-03T18:52:45.720 回答