Phil
Phil

Reputation: 7

Excel countif -

Excel countif - I need to count a list of policies that are within a date range (expired policies) and include specific transaction types.

Originally, I needed to do the countif based on excluding values. Now as the transaction types have grown, it would be more efficient to just include the values I want. Below was the formula based on excluding certain values.

=COUNTIFS(A1:A4,"<"&DATE(2018,1,15),B1:B4,"<>"&"Can",B1:B4,"<>"&"END") allows me to exclude values I don't want recorded.

Policies are defined by transaction type: New,Ren,End,Can, REN-1,REN-2 etc...

I only want to count New and Ren within the date formula above however when I edit the above formula to =COUNTIFS(A1:A4,"<"&DATE(2018,1,15),B1:B4,"New",B1:B4,"REN") I just get a 0 value Thanks for reading

Upvotes: 0

Views: 100

Answers (1)

cybernetic.nomad
cybernetic.nomad

Reputation: 6418

I will go out on a limb and assume your question is "What's wrong with my formula?".

Try:

=COUNTIF(C6:C978,"<"&DATE(2018,10,31))

Edit: For multiple criteria you must use COUNTIFS:

=COUNTIFS(A1:A4,"<"&DATE(2018,1,15),B1:B4,"<>"&"Can",B1:B4,"<>"&"END")

Upvotes: 2

Related Questions