Unanswered: Expression for Query to Sort by Todays Date
I have a Access query that needs to generate a report with only the records generated on the same day. For example, I generated 10 records in my database today, which is in addition to the prior records from the past few days. I would like my report to only show the records I made today, then tomorrow, etc...
Actually, the easiest way to do a "report for today" is to base the report on a query that includes the criteria "= Date()" for the appropriate field. The query returns only today's results.
It's a little more complicated if you're working on a Timestamp type field (date and time), but not a lot.
If you want the report to summarize several days, by date, then you need a field in the report-query that returns the day. Then group your report output by that field. A separate group of rows will be produced for each.
for exclude the time :
SELECT Table1.*, Format([champ2],"dd/mm/yyyy") AS expr1
WHERE (((Format([champ2],'dd/mm/yyyy'))=Date())) OR (((Format([champ2],'dd/mm/yyyy'))=Date()));
Format(xxxx,'dd/mm/yyyy') depend of your régional setting and in which format you stored the date in your data base