Lewis said:
Thanks, James. It was just what I needed. I do have another question,
however. How do I limit the results to show just the current year's records?
The combination of over 30 days old and in the same calendar year will
always be false in January (well, except maybe the 31st) and of
questionable value in the first few months of any year.
Did you really mean to check the last 365 days? If so, you could modify
James's solution to look like
Between (Date()-30)) And (Date()-365))
If you really wanted to do as you said,
Add to your WHERE clause:
AND YEAR(TableName.DateField) = YEAR(DATE)
The the query builder this might look like (in a new column):
Field: YEAR(TableName.DateField)
Show: no
Criteria: = YEAR(DATE)
[message with incorrect attribution was canceled -- apologies to James
for any confusion]