Need help with formula

new2excel__12

New Member
Joined
Aug 17, 2022
Messages
14
Office Version
  1. 365
Platform
  1. Windows
  2. Web
I have a list of all of the members of our company, and I also have 7 other lists (2016-2022) of all members that renewed their membership each year. I need to go through each of these lists, compare it to the main list, create new columns for each year, and put "yes" for the people that renewed their membership in each year.

I tried conditional formatting, found duplicates, and manually put yes under each name, but is there a faster way? I want to avoid going through each list and putting yes under each duplicate. Thanks a lot in advance!!
 

Excel Facts

How to total the visible cells?
From the first blank cell below a filtered data set, press Alt+=. Instead of SUM, you will get SUBTOTAL(9,)
Welcome to the Board!

There are numerous ways to do, i.e. using formulas like VLOOKUP, XLOOKUP, INDEX/MATCH though I would probably prefer a simple COUNTIF formula with an IF.
So it would be structured something like this:
Excel Formula:
=IF(COUNTIF(...)>0,"Yes","")

If you are unfamiliar with COUNTIF, see here: MS Excel: How to use the COUNTIF Function (WS)
If you need help, please provide the layout details (i.e. ranges) of all your data and where the expected output should be (maybe some images).
 
Upvote 0
Welcome to the Board!

There are numerous ways to do, i.e. using formulas like VLOOKUP, XLOOKUP, INDEX/MATCH though I would probably prefer a simple COUNTIF formula with an IF.
So it would be structured something like this:
Excel Formula:
=IF(COUNTIF(...)>0,"Yes","")

If you are unfamiliar with COUNTIF, see here: MS Excel: How to use the COUNTIF Function (WS)
If you need help, please provide the layout details (i.e. ranges) of all your data and where the expected output should be (maybe some images).
Thank you so much for your quick response. Unfortunately, I wasn't able to figure it out on my own. I have attached an image to this reply. Would you please be able to help me with the formula? Thank you again so much for taking the time to respond.


In column C I have full names of all members of all times. In column D only people who renewed in 16-17, and in E, who renewed in 17-18.
I want to use a formula that will compare names in column D to column C and if there is a duplicate put YES under column F. Also have formula that will compare column E and C and if there are duplicates put YES in column G. Does this make sense?
 

Attachments

  • Screenshot 2022-08-17 111941.png
    Screenshot 2022-08-17 111941.png
    12 KB · Views: 6
Upvote 0
Place this formula in cell F2:
Excel Formula:
=IF(COUNTIF(D:D,$C2)>0,"Yes","No")
and then copy to the range F2:G4 and it should return the correct results.
 
Upvote 0
Place this formula in cell F2:
Excel Formula:
=IF(COUNTIF(D:D,$C2)>0,"Yes","No")
and then copy to the range F2:G4 and it should return the correct results.
Thank you so much for your reply. I really appreciate it! Unfortunately, it did not quite work, maybe I am doing something wrong? I have attached a screenshot of the first 3 people and E1 should say no instead of yes. Did I misinterpret the formula?
 

Attachments

  • 111111111111111.png
    111111111111111.png
    11 KB · Views: 5
Upvote 0
This is what it shows for me:
1660831418380.png


The only way it should show a "Yes" in cell E5 is if you have the value "Betker Alexis" somewhere in column D. Are you sure you don't have it further down the column?

We could limit our formula to just the cells shown, as you should see it work then, i.e.
Excel Formula:
=IF(COUNTIF($D$2:$D$4,$C2)>0,"Yes","No")
It just isn't as dynamic then, as you may need to change the ending row numebr depending on how much data you have.
 
Upvote 0
Solution
This is what it shows for me:
View attachment 71918

The only way it should show a "Yes" in cell E5 is if you have the value "Betker Alexis" somewhere in column D. Are you sure you don't have it further down the column?

We could limit our formula to just the cells shown, as you should see it work then, i.e.
Excel Formula:
=IF(COUNTIF($D$2:$D$4,$C2)>0,"Yes","No")
It just isn't as dynamic then, as you may need to change the ending row numebr depending on how much data you have.
Oh yes! you are absolutely right. I found my mistake. Thanks so much! Really appreciate your help!! It would have taken me hours to do otherwise!!
 
Upvote 0
You are welcome.
Glad I was able to help.
 
Upvote 0

Forum statistics

Threads
1,214,987
Messages
6,122,618
Members
449,092
Latest member
amyap

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