Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi all,
Our definition is that for YearToDate (YTD) we take max 52 weeks. Normally we defined PastYear YTD (PYYTD) as Commercialyear -1 and took the same (max) week. Now we've changed our formula and it works fine directly in the expression. But we work with include variable files (.txt). If I place the variable in the file it doesn't work anymore. THe only change to the expression is that in the variable we need to use the ALT codes.
Can you please help me?
LET vNetSalesPYYTD = 'sum({<CommercialYear=,Week=,WeekSerial={">='&CHR(36)&'(=max(WeekSerial-if(Week='53', 52, 52+Week-1))),<='&CHR(36)&'(=max(WeekSerial-52))"}>}Sales)';
Best regards,
Astrid
I've found the solution:
LET vNetSalesPYYTD = 'sum({<CommercialYear=,Week=,WeekSerial={">='&CHR(36)&'(=max(WeekSerial-if(Week="53", 52, 52+Week-1))),<='&CHR(36)&'(=max(WeekSerial-52))"}>}Sales)';
so it was " in stead off '
I've found the solution:
LET vNetSalesPYYTD = 'sum({<CommercialYear=,Week=,WeekSerial={">='&CHR(36)&'(=max(WeekSerial-if(Week="53", 52, 52+Week-1))),<='&CHR(36)&'(=max(WeekSerial-52))"}>}Sales)';
so it was " in stead off '