By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
429,384 Members | 714 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 429,384 IT Pros & Developers. It's quick & easy.

Date Query removing present month

P: 2
In this code I am pulling particular totals for all 12 months off of a table. This is an on going query that pulls monthly. I want to exclude the current month from this query. How can I get it to not include current month but all previous? I know I need to exclude (today) part but I am not sure what to put in its place..

Expand|Select|Wrap|Line Numbers
  1. ....> dateserial(year(today),month(today)-12,1)
Feb 15 '12 #1

✓ answered by Rabbit

You can use the BETWEEN predicate to filter between two dates.

Share this Question
Share on Google+
1 Reply


Rabbit
Expert Mod 10K+
P: 12,359
You can use the BETWEEN predicate to filter between two dates.
Feb 15 '12 #2

Post your reply

Sign in to post your reply or Sign up for a free account.