Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
hello,
We have data coming in every alternate year 2 different departments. For example, 2018 we get data for Department A, 2019 for Department B, 2020 for Department A, 2021 for Department B and so on...
I would like to display a text based off the year, for even years - it should display the
even years - department A
odd years - Department B
How can I write the set expression to achieve this?
Use the same logic that displays the previous year's data to populate the year in the formula
If(Mod (Year,2) = 0,'Department A','Department B')
Not the selected year
Thank you. It works.
Also, I have to display text that says data is for 2018 for Department A, when the user clicks on 2019, it should still say data displayed is for 2018 Department A as technically there's no data in 2019 for Department A. When user clicks 2020, it should say data displayed is for 2020 Department A.
2018 - Data is for 2018 Department A
2019 - Data is for 2018 Department A
2020 - Data is for 2020 Department A
In the text, Do I need a variable for on year to manipulate the year?
Why is data still showing if you choose a year without data?
That was the client's requirement to display previous year's data. They didn't want it to be blank.
Use the same logic that displays the previous year's data to populate the year in the formula
If(Mod (Year,2) = 0,'Department A','Department B')
Not the selected year
So you mean, Data displayed below for Department A is from & &' if(Mod(Year,2) = 0,'DepartmentA,'DepartmentB') ?? the expression doesn't work.
I need to show the text as "Data displayed for Department A is from 2018" - when 2018 is selected
"Data displayed for Department A is from 2018" - when 2019 is selected
"Data displayed for Department A is from 2020" - when 2020 is selected
Same way for Department B
"Data displayed for Department B is from 2019" - when 2019 is selected
"Data displayed for Department B is from 2019" - when 2020 is selected
"Data displayed for Department B is from 2021" - when 2021 is selected
Hope I'm explaining the requirement clearly. Thank you for your help.