Reputation: 157
I'm trying to flag certain conditions as an error when performing some data audits. But unfortunately my date criteria seems to not be working. I have a date stored in column BI. I have tried the following formula:
=IF(AND(H3="A",AN3="CTO",BB3<>"8",BI3>="10/1/2017"),"Error","Good")
The logic (H2 = "A", AN3 = "CTO", BB3 <> "8", and BI3 > 10/01/2017) should produce an error. But it does not and I suspect it's the date portion of the formula. I have also tried:
=IF(AND(H3="A",AN3="CTO",BB3<>"8",BI3>=DATE(2017,10,1)),"Error","Good")
But that did not work either. Any help would be greatly appreciated. Thanks in advance!
Upvotes: 1
Views: 182
Reputation: 185
You are comparing a date to a string. Different datatypes. Try this:
=IF(AND(H3="A",AN3="CTO",BB3<>"8",BI3>=DATEVALUE("10/1/2017")),"Error","Good")
Also, is BB3 a number? If it is not stored as a string, you might want to remove the quotes around 8 as it forces an implicit conversion.
Upvotes: 1