Avatar of kbay808
kbay808Flag for United States of America asked on

How to set the date filter in an excel pivot table to “Before =TODAY()”

I have a pivot table that needs to be filtered to show all the records before the current date.  Here is the way that I do it right now.  Date Filters>Before> (Today’s date).  It will not accept “=TODAY()” as the value, so I have to manually set this every day.  Is there another way to accomplish this?
Microsoft Excel

Avatar of undefined
Last Comment

8/22/2022 - Mon


I could not get it to work.  I attached the workbook so you can see what I’m working with along with the key data for the macro.
Rob Henson

Add a column to the source data with the following formula, assuming date is in column A:


This will return TRUE or FALSE.

If you then add the column into the Pivot Table you can filter on TRUE.

Rob H
I started with Experts Exchange in 2004 and it's been a mainstay of my professional computing life since. It helped me launch a career as a programmer / Oracle data analyst
William Peck

Using "=A1<TODAY()" won't work, because the field also contain blanks.
Rob Henson

Log in or sign up to see answer
Become an EE member today7-DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform
Sign up - Free for 7 days
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
See how we're fighting big data
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
ask a question

That worked perfectly.  Thanks