Home > OS >  google sheets array formula for counting the number of times a value appears in comparison to anothe
google sheets array formula for counting the number of times a value appears in comparison to anothe

Time:09-22

I am trying to get the count for how often a value appears in comparison to another. Here is the Array. =ARRAYFORMULA(IF(ROW(A2:A)=2,"Manual Type",IF(B2:B="","",COUNTIF('2021ContractsData'!L:L,"Where L='Manual (M)'",B2:B))))

B already has the populated listings to compare to. 2021ContractsData'!L:L is column with only 2 options in its drop down. First drop down option is Manual (M). I am needing a count of how many times the value in L column appears in comparison to B. My error is an arguement error. CountIF is looking for 2 and sees 3.

CodePudding user response:

try:

=ARRAYFORMULA({"Manual Type"; 
 COUNTIF(2021ContractsData!B3:B, 2021ContractsData!L3:L="Manual (M)")})

CodePudding user response:

I was able to get it to work with the following.

=ARRAYFORMULA(IF(ROW(A2:A)=2,"Manual Type",IF(B2:B="","",COUNTIFS('2021ContractsData'!L2:L,"Manual(M)",'2021ContractsData'!H2:H,B2:B))))

  • Related