So I only have a CreatedDate to work with.
I have a scheduled task that runs everyday at 12 midnight and that needs to get all records that fall on the same day of the month (but not if the CreatedDate == DateTime.Now).
I would prefer this to be in LINQ since this is a database call but any iteration logic would suffice, I think.
I have this right now but this has problems with days higher than 28:
var results = Context.Subscriptions.Where(
x => !(x.StartDate.Day == DateTime.Now.Day &&
x.StartDate.Month == DateTime.Now.Month &&
x.StartDate.Year == DateTime.Now.Year) &&
x.StartDate.Day == DateTime.Now.Day);
Updating the question for clarity:
For example, a record's created date is January 31 2013. This record should get pulled every month. But since not all months have 31 days, my code above won't work on those months. I still need to pull the record every month even if that month has no 31st.