Forum Discussion
packie
May 11, 2024Brass Contributor
Add an additional condition where the value is greater than 0
Hi folks,
The following formula is used to return the number of times a week number is found in Sheet1
=COUNTIF(Sheet1!$R$5:$R$1000,D24)
Now I only want the number of times the week number is found to only return a result if the value(s) in colO has a value greater than (0)
The range to include in the formula:
Sheet1!$O$5:$O$1000
To give you a better idea what I am looking to do here is my (poor) attempt to include the condition in the original formula:
=COUNTIF((Sheet1!$R$5:$R$1000,D24),Sheet1!$O$5:$O$1000, >0))
Thank you for taking a look!
The COUNTIFS() function is suitable for this: So:
=COUNTIFS(Sheet1!$R$5:$R$1000,D24,Sheet1!$O$5:$O$1000,">0")