Jun 25 2023 03:11 AM
Could anyone help with how I can change date automatically in the formula below when I copy this formula down in excel.
=GETPIVOTDATA(" Total sales",'5.Rev-cost food'!$A$1,"Date",DATE(2023,6,24))
At present i have to change the date manually each day. Next d5)ate above would be
DATE(2023,6,25))
thanks
Jun 25 2023 04:18 AM
Hi @CharlieWR
One way:
=GETPIVOTDATA(" Total sales", '5.Rev-cost food'!$A$1, "Date", DATE(2023,6,23)+ROWS($1:1))
it's really DATE(2023,6,23)
Jun 25 2023 05:29 AM
Most probably PivotTable has Date, like
If so formula could be
=GETPIVOTDATA("Total Sales",'5.Rev-cost food'!$A$1,"date",'5.Rev-cost food'!$A2)
and drag it down
Jun 25 2023 03:33 PM
SolutionJun 25 2023 11:59 PM
@CharlieWR , you are welcome