简体   繁体   中英

Excel Countifs formula

I have nested the below IF/AND/COUNTIFS formula. The logic is based on the country in column N, refer to specific range on another sheet in the same WB. The problem I am running into is I am getting FALSE results when it should be TRUE. I have triple checked all my ranges. And all values on both sheets are formatted as General. An

=IF(AND(N2="Australia")*COUNTIFS(Ratings!A$2:A$14,'Sheet 1'!AT2,Ratings!B$2:B$14,'Sheet 1'!AU2),TRUE,
IF(AND(N2="Brazil")*COUNTIFS(Ratings!D$2:D$13,'Sheet 1'!AT2,Ratings!E$2:E$13,'Sheet 1'!AU2),TRUE,
IF(AND(N2="CanadaEnglish")*COUNTIFS(Ratings!G$2:G$19,'Sheet 1'!AT2,Ratings!H$2:H$19,'Sheet 1'!AU2),TRUE,
IF(AND(N2="CanadaFrench")*COUNTIFS(Ratings!J$2:J$19,'Sheet 1'!AT2,Ratings!K$2:K$19,'Sheet 1'!AU2),TRUE,
IF(AND(N2="France")*COUNTIFS(Ratings!P$2:P$21,'Sheet 1'!AT2,Ratings!Q$2:Q$21,'Sheet 1'!AU2),TRUE,
IF(AND(N2="Germany")*COUNTIFS(Ratings!M$2:M$17,'Sheet 1'!AT2,Ratings!N$2:N$17,'Sheet 1'!AU2),TRUE,
IF(AND(N2="Italy")*COUNTIFS(Ratings!S$2:S$7,'Sheet 1'!AT2,Ratings!T$2:T$7,'Sheet 1'!AU2),TRUE,
IF(AND(N2="Mexico")*COUNTIFS(Ratings!V$2:V$17,'Sheet 1'!AT2,Ratings!W$2:W$17,'Sheet 1'!AU2),TRUE,
IF(AND(N2="Spain")*COUNTIFS(Ratings!Y$2:Y$24,'Sheet 1'!AT2,Ratings!Z$2:Z$24,'Sheet 1'!AU2),TRUE,
IF(AND(N2="United Kingdom")*COUNTIFS(Ratings!AB$2:AB$13,'Sheet 1'!AT2,Ratings!AC$2:AC$13,'Sheet 1'!AU2),TRUE,
IF(AND(N2="USA")*COUNTIFS(Ratings!AE$2:AE$20,'Sheet 1'!AT2,Ratings!AF$2:AF$20,'Sheet 1'!AU2),TRUE)))))))))))

在此处输入图片说明

在此处输入图片说明

Any thoughts?

you formula is working perfect there is nothing wrong in it.

Please check below sample what i have tried as like you. It's working for me and it returns True when actually the conditions are perfect.

Hope this is what your tried for, if not please elaborate your question. So that this will be solved.

And please check you formula option is Automatic or Manual.

Note: I Just copied you formula, and changed reference for Germany and it works perfect.

Sheet 1 as per your formula:

在此处输入图片说明

Sheet 1 My Own Written Formula as Like yours:

在此处输入图片说明

Ratings Sheet:

在此处输入图片说明

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

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