Adding a date filter is usually a fairly trivial task, and using the [Today] technique is a great way to get dates in and around today ([Today]-1 for yesterday, [Today]+1 for tomorrow, etc.). But what about when you want to filter against a specific date?
As it turns out the date format in a filter is always in the format Month / Day / Year (in the format MM/DD/YYYY, so 02/25/2010) – as seen below.
Shortcuts will also work as seen below. | |
02/08/2010 can also be written any of the following ways:
2/08/2010 or 02/8/2010 or 2/8/2010 or 02/8/10 or 2/08/10 or 2/8/10 |
|
However, be sure to use valid dates | |
I.e. 4/35/2010 won’t work and you’ll get the following error, “Filter value is not in a supported date format”. |
How would I make this dynamic? If I have a startDate column and I want to show all items in the list with a start date occurring this year only? I tried
greater than or equal to
date(year([today]), 1,1) and less than date(year([today])+1, 1,1)
But does not work. Complains of invalid format.
What if you want to filter on just the records that have no date in that date field? How do you do that?
Just leave the field blank. Column name example, Date, is equal to, (blank). Do not type anything in the field.