This is driving me crazy! What am I missing?
Here's my query:
SELECT tblRelease.ID, tblRelease.Application, tblRelease.Date, DateAdd("d",tblRelease.DateVariance,tblRelease.Date) AS ToDate, tblRelease.Time, tblRelease.Description
FROM tblRelease
WHERE (DateAdd("d",tblRelease.DateVariance,tblRelease.Date)>=[Enter Effective Date])
ORDER BY tblRelease.Application, tblRelease.Date;
I've chopped out a few fields to make it a bit smaller and easier to read.
The problem is that whilst the DateAdd() in the SELECT clause produces exactly the date that I want, the DateAdd() in the WHERE clause does not seem to work. I always get all records no matter what date I enter for [Enter Effective Date]. If I change the WHERE clause to
WHERE (tblRelease.Date>=[Enter Effective Date])
then everything works perfectly and I get different numbers of records depending on the date I enter.
I am entering the date in the form 01/08/2005 and this works for the second variation just fine. It's dd/mm/yyyy in case that's important (my local default).
Anybody see my problem?
Here's my query:
SELECT tblRelease.ID, tblRelease.Application, tblRelease.Date, DateAdd("d",tblRelease.DateVariance,tblRelease.Date) AS ToDate, tblRelease.Time, tblRelease.Description
FROM tblRelease
WHERE (DateAdd("d",tblRelease.DateVariance,tblRelease.Date)>=[Enter Effective Date])
ORDER BY tblRelease.Application, tblRelease.Date;
I've chopped out a few fields to make it a bit smaller and easier to read.
The problem is that whilst the DateAdd() in the SELECT clause produces exactly the date that I want, the DateAdd() in the WHERE clause does not seem to work. I always get all records no matter what date I enter for [Enter Effective Date]. If I change the WHERE clause to
WHERE (tblRelease.Date>=[Enter Effective Date])
then everything works perfectly and I get different numbers of records depending on the date I enter.
I am entering the date in the form 01/08/2005 and this works for the second variation just fine. It's dd/mm/yyyy in case that's important (my local default).
Anybody see my problem?