Countifs based on 'contains' but references a cell in table

Melimob

Active Member
Joined
Oct 16, 2011
Messages
396
Office Version
  1. 365
Hi I have the below formula

I basically want to count if the country in my current table appears within text in my country column in table1
Also since I want to absolute reference the PM, I've use $C$2 as I didn't know how to absolute reference the cell in a table if I just clicked on it. It would appear as ,[@Country] but then would try and move to next row if I copied down the formula.


=COUNTIFS(Table1[Country],"*[@Country]*",Table1[PM],$C$2)

I also want to use a similar count but add in a 3rd argument based on date which would be referenced on header row of both columns

thanks for any advice
 

Excel Facts

How to calculate loan payments in Excel?
Use the PMT function: =PMT(5%/12,60,-25000) is for a $25,000 loan, 5% annual interest, 60 month loan.
Hi I have the below formula

I basically want to count if the country in my current table appears within text in my country column in table1
Also since I want to absolute reference the PM, I've use $C$2 as I didn't know how to absolute reference the cell in a table if I just clicked on it. It would appear as ,[@Country] but then would try and move to next row if I copied down the formula.


=COUNTIFS(Table1[Country],"*[@Country]*",Table1[PM],$C$2)

I also want to use a similar count but add in a 3rd argument based on date which would be referenced on header row of both columns

thanks for any advice

OK got the 1st to work but had to reference range cell instead of table name

=COUNTIFS(Table1[Country],"*"&D3&"*",Table1[PM],$C$2)

now going to try and add in 3rd match
 
Upvote 0

Forum statistics

Threads
1,223,893
Messages
6,175,240
Members
452,621
Latest member
Laura_PinksBTHFT

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top