# Update COUNTIF Formula When Using Tables

1. ## Update COUNTIF Formula When Using Tables

I'd like the formulas to update based on the filtered data I have in my table. In the example, if I choose under column C "Date Shipped" all January dates I would want the quantities in A2:A4 to update. Then if I choose February update again and so on. I've been using a variety of various attempts but nothing has worked. The example sheet is attached and thanks in advance!

2. ## Re: Update COUNTIF Formula When Using Tables

Your 2-4 days is wrong. The way you have that formula set up...
=(COUNTIF(F7:F12,">=2")+COUNTIF(F7:F12,"<4"))
it is counting all values >=2 PLUS all values <4
If you break it down into 2 formulas you will see 4 + 4

A2=SUMPRODUCT(SUBTOTAL(3,OFFSET(\$A\$7,ROW(\$A\$7:\$A\$12)-ROW(\$A\$7),)),--(\$F\$7:\$F\$12<=1))
A3=SUMPRODUCT(SUBTOTAL(3,OFFSET(\$A\$7,ROW(\$A\$7:\$A\$12)-ROW(\$A\$7),)),--(F7:F12>=2),--(F7:F12<=4))
A4=SUMPRODUCT(SUBTOTAL(3,OFFSET(\$A\$7,ROW(\$A\$7:\$A\$12)-ROW(\$A\$7),)),--(\$F\$7:\$F\$12>=5))

Keep in mind you have 6 entries, so te combination of ANY counts that you do, cannot exceed that, else you are including entries more than once

3. ## Re: Update COUNTIF Formula When Using Tables

Thanks- this is perfect!

4. ## Re: Update COUNTIF Formula When Using Tables

Happy to help and thanks for the feedback

There are currently 1 users browsing this thread. (0 members and 1 guests)

#### Posting Permissions

• You may not post new threads
• You may not post replies
• You may not post attachments
• You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1