Access Query current quarter

Godders199

Active Member
Joined
Mar 2, 2017
Messages
313
Office Version
  1. 2013
Hello, i am trying to run an access query with the following date criteria, but when i run it just returns all the rows that match the other criteria specified, not just for the current quarter

Year([todays date])=Year(Now()) And DatePart("q",Date())=DatePart("q",Now())

from the view , if i click on the filter for the column todays date , i get the following error message " Syntax error (missing operator in query expression "todays date"

I just cant see any thing wrong.

Any help would be appreciated.
 

Excel Facts

What is the shortcut key for Format Selection?
Ctrl+1 (the number one) will open the Format dialog for whatever is selected.
what is [todays date] and where is this written - in code or a query? If it's code, you need date delimiters.
You should provide the rest of the sql or related code since by itself, it doesn't make much sense to me. Either side of the AND will be either True or False, which is incomplete when taken by itself.
 
Last edited:
Upvote 0
Hi, [todays date] is just the column heading, and is just written within a Query I had created in the criteria field, as a temp fix i have changed the criteria to >#01/04/2018# which works, just means at the start of each quarter i will need to amend.
 
Upvote 0

Forum statistics

Threads
1,214,833
Messages
6,121,857
Members
449,051
Latest member
excelquestion515

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top