Hey Guys,
I have a query the takes the current month and filters the criteria to give me the last day of that month and the last day of that same month one year ago.
So it looks like (for instance)
give me everything Between 20170731 and 20180731
So it looks like this in the query criteria
Is there a cleaner and faster way to write this? It works but it seems like a mess. (and slower as well)
Any Ideas?
I have a query the takes the current month and filters the criteria to give me the last day of that month and the last day of that same month one year ago.
So it looks like (for instance)
give me everything Between 20170731 and 20180731
So it looks like this in the query criteria
Code:
Between Format(DateAdd("yyyy",-1,DateSerial(Year(Date()),Month(Date())+1,0)),"yyyymmdd") And Format(DateSerial(Year(Date()),Month(Date())+1,0),"yyyymmdd")
Is there a cleaner and faster way to write this? It works but it seems like a mess. (and slower as well)
Any Ideas?