简体   繁体   English

Google Sheet 创建 IF 或 IFS

[英]Google Sheet creating an IF or IFS

I am trying to auto populate information based on what I am inputting into one column to another.我正在尝试根据我输入到另一列的内容自动填充信息。

For example: Column D has a list I choose from: CD, DD, CC, Closed.例如:D 列有一个我可以选择的列表:CD、DD、CC、Closed。 Based on what is input in Column D in each row I am looking to populate that information in each individual rows for column N though P.根据每行 D 列中输入的内容,我希望在 N 列到 P 列的每一行中填充该信息。

D2=Closed, N though P should state NA. D2=Closed, N 虽然 P 应该声明 NA。

D3=CD or DD or CC. D3=CD 或 DD 或 CC。 N though P is left blank. N 虽然 P 留空。

When I try IFS function it will state the NA if D is Closed but for CD, DD or CC it will spilt out False.当我尝试 IFS 函数时,如果 D 已关闭,它将说明 NA,但对于 CD、DD 或 CC,它将溢出 False。 How do I leave the NP columns blank if D3 or other D columns are not equal to Closed?如果 D3 或其他 D 列不等于 Closed,如何将 NP 列留空?

尝试:

=ARRAYFORMULA(IF(D2:D="Closed", {"NA","NA","NA","NA"}, ))

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

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