Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I create two variables
vWeekSelected
=if(IsNull(GetFieldSelections(Week,'*')),Year={$(=max(Year)),Weekyear= {$(=max(Weekyear))})
vLastYearSelected
=if(IsNull(GetFieldSelections(Week,'*')),Year={$(=max(Year-1)),Weekyear= {$(=max(Weekyear-1))})
I declare two expressions
pricethisyear
Sum( {<$(vWeekSelected)>} [Prix de vente TTC])
pricelastyear
Sum( {<$(vLastYearSelected)>} [Prix de vente TTC])
pricethisyear and pricelastyear return the same value which is wrong . How to correct it ?
max(Year-1)
should be
Max(Year)-1
Hi,
The set modifier is not ended properly for Year parameter, use the below
vWeekSelected=if(IsNull(GetFieldSelections(Week,'*')),Year={$(=max(Year))},Weekyear= {$(=max(Weekyear))})
vLastYearSelected
=if(IsNull(GetFieldSelections(Week,'*')),Year={$(=max(Year-1))},Weekyear= {$(=max(Weekyear-1))})
Also please check if the field names are used correct (Case sensitive)