Matching cells returning FALSE when comparing the "Year" in dates

Monty85

New Member
Joined
May 6, 2019
Messages
43
Office Version
  1. 365
Platform
  1. Windows
Can anyone assist with a formula that will work in the below example. I need to compare a list of dates against another source that has intermittent data - dates are in text format, in YYYY,MM,DD format and half the data is the year only.

I want to compare the Year between the two data sets but im not sure if i'm going about it the right way.

MERCER_BT_AUS_PEP_03042023 - Validations (less formulas).xlsx
ABCDE
1Date_1Year OnlyDate_2Year OnlyCheck
215/04/1970197019701970FALSE
31/05/198919891989/05/011989FALSE
425/03/1999199919991999FALSE
515/07/198619861986/07/151986FALSE
68/09/1967196719671967FALSE
Sheet5
Cell Formulas
RangeFormula
D2:D6D2=LEFT(C2,4)
E2:E6E2=D2=B2
B2:B6B2=YEAR(A2)
 

Excel Facts

Excel Joke
Why can't spreadsheets drive cars? They crash too often!
You are comparing a string vs an integer. Maybe just add something like:

Excel Formula:
=--RIGHT(C2,4)
 
Upvote 1
Solution

Forum statistics

Threads
1,215,340
Messages
6,124,382
Members
449,155
Latest member
ravioli44

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