measure - PowerPivot: Aggregating 'SAMEPERIODLASTYEAR' Sales by Year, Qtr etc -
i've created new measure uses [totalsales] , 'sameperiodlastyear' calculate previous year's sales, see below:
=calculate([totalsales], sameperiodlastyear(dates[date]))
this works fine if create pivot displays individual dates (e.g. 01/01/2015) , new measure 'previous year sales' value next it. problem occurs when want change pivot , display previous year sales year, quarter or month - of these options no sales value.
i'm using 'dates' table linked sales table.
am right in thinking can re-aggregate sales in way? have seen error message says not been able aggregate non-contiguous value or date.
i've had see if else has experienced same problem, can't see anything. guidance helpful.
regards, martyn
yes can re-aggregate in way. formula correct handles changes aggregation level.
i check 'dates' table marked date table. ensure year, quarter & months in date table , not in sales table. make sure date table has 1 record each day between beginning of sales data set , end. check behavior in power view if using excel 2013.
Comments
Post a Comment