Forum

Notifications
Clear all

GETPIVOTTABLEDATA date question

5 Posts
3 Users
0 Reactions
91 Views
(@wxadkin)
Posts: 18
Eminent Member
Topic starter
 

I have the following GETPIVOT call:

GETPIVOTDATA("Status",$O$29,"Status","Analysis","Today",DATE(2021,6,7),"Sprint",1)

I want the underlaying pivot table to update automatically when a new raw data table entry is made. This works, however, one column in the table is based on the TODAY() function. This is to gather stats on what has changed since the last file run. This date is in the pivot table, and it changes as expected with the base table containing the new data changes.

 

The issue:

It appears that the date in the GETPIVOT call is not changing even though the date in the pivot table updates: Example:

Today: GETPIVOTDATA("Status",$O$29,"Status","Analysis","Today",DATE(2021,6,7),"Sprint",1)

Updated base table to 6/8/2021:

GETPIVOTDATA("Status",$O$29,"Status","Analysis","Today",DATE(2021,6,7),"Sprint",1), as you can see no change. I need the date to change so the target of the GETPIVOT call will have data populated under the new date.

Suggestions?

 
Posted : 08/06/2021 10:23 am
(@mynda)
Posts: 4761
Member Admin
 

Hi William,

Change the DATE formula to something dynamic like this: 

=GETPIVOTDATA("Status",$O$29,"Status","Analysis","Today",DATE(YEAR(TODAY()),MONTH(TODAY()),DAY(TODAY())),"Sprint",1)

Mynda

 
Posted : 08/06/2021 8:04 pm
(@debaser)
Posts: 836
Member Moderator
 

Wouldn't you just use TODAY() rather than DATE(YEAR(TODAY()),MONTH(TODAY()),DAY(TODAY()))?

 
Posted : 09/06/2021 4:42 am
(@mynda)
Posts: 4761
Member Admin
 

🙂 of course. I was thinking at the time that the value in that argument is text, as most of them are in GETPIVOTDATA and that it had to be in a specific format...not that my formula returned that anyway...all I can say is it was early in the morning and I shouldn't answer questions before having eaten breakfast! At least we have sensible people like you correcting silly errors. Thanks, Velouria!

 
Posted : 09/06/2021 5:00 am
(@debaser)
Posts: 836
Member Moderator
 

🙂 No worries - just wanted to check I wasn't missing something!

 
Posted : 09/06/2021 5:08 am
Share: