I have a list of dates like this:
DateTime now = DateTime.Today;
var expiriesDays = new List<int> { 1, 7, 14 };
List<DateTime> expiriesDates = expiriesDays.Select(x => now.AddDays(x).Date).ToList();
Now I have one table and it has field with name ComplianceExpiryDate, now I want to check if this field has any value from expiriesDates.
Like any record has value like 13-07-2021 OR 19-07-2021 OR 26-07-2021 in ComplianceExpiryDate
I just want to compare with Date, not time.
I tried with TruncateTime but, DbFunctions does not show this function to use and is throwing an error.