10 Replies Latest reply: Apr 5, 2017 5:23 PM by Salim DERGHOUM

# prior year

Hello everyone,

I hope that you can help me. Indeed, I want display two value side by side in a bar chart, first value for the year select and second value for the prior year. I use this formula in set analysis annee={\$(=(annee-10))} (10 because it's ten by ten).

But nothing display in my bar chart.

Do you have any idea to help me ?

Best regards,

SD

• ###### Re: prior year

Try this

annee={\$(=Max(annee)-10)}

• ###### Re: prior year

Values display are still values of year select only...

• ###### Re: prior year

Can you show a screenshot of the field annee?

• ###### Re: prior year

Yes, you can see with this picture :

Before annee was a String but I modifiy in integer in the database and I refresh data.

• ###### Re: prior year

Are you making selection in other Date and Time related fields?

• ###### Re: prior year

I use your expression without and with selection on annee field. Because, I want when I will select value 1981, I want value for 1971 and 1981 side by side.

• ###### Re: prior year

I try to create a variable like this anneeV : \$(=annee+10). Then I use this variable in a set analysis like this : sum(\${<nom_Mesure={exp}, annee={\$(=anneeV)}, nom_Du_Pays-={'Monde'}} valeur).

But value display are this of current year select...

• ###### Re: prior year

Sum(\${<nom_Mesure={exp}, annee={\$(=Max(annee) - 10)}, nom_Du_Pays-={'Monde'}} valeur)

• ###### Re: prior year

Try this:

Sum({<annee=,annee={"\$(=max(annee))","\$(=max(annee)-5)"}>}YourMeasure)

• ###### Re: prior year

Thanks, but my formula work finally, I need to add ">" before "}".