Forum Discussion
Calculation items removes Web URL from values - how to fix?
- 2 years ago
Again, really appreciate your effort - though the problem still remained.
So the problem seemed to be related to the calculation item "Actuals", that returns blank when the selected measure name does not contain "actuals". So the Web URL measure was simply set to blank as its name does not contain "actuals" in it.
So I tried to to change the calculation item telling it to return the selected measure when the selected measure name either contain "Actuals" or "Web URL" - and it works now!
Calculation item changed to...
Actuals=IF (CONTAINSSTRING(SELECTEDMEASURENAME(), "Actuals") ||CONTAINSSTRING(SELECTEDMEASURENAME(), "Web URL"),SELECTEDMEASURE(),BLANK())
Dear ahadkarimi ,
Appreciate your effort. The suggested measures did not solve the issue. When the calculation item is selected and filtered in the report slicer, the URL disappears from the values. The values though, are still shown.
Additional information, when calculation item "Actuals" is selected the URL disappears, BUT when multiple selections are made the URL returns, for example when "Budget" is added to the selection.
- ahadkarimi2 years ago
Solution Specialist
Hi Mjolnir, try these updated measure below, and if you encounter any issues, let me know.
Web URL = IF ( ISFILTERED(fact_table[verificationnumber]), CALCULATE ( MAX(dim_links[URL]), dim_organization[orgcode] = SELECTEDVALUE(dim_organization[orgcode]), dim_calendar[year] = SELECTEDVALUE(dim_calendar[year]), FILTER ( fact_table, fact_table[verificationnumber] IN VALUES(fact_table[verificationnumber]) ) ), IF ( HASONEVALUE('CalculationGroup'[CalculationItem]), SWITCH( TRUE(), SELECTEDMEASURENAME() = "Actuals", CALCULATE ( MAX(dim_links[URL]), dim_organization[orgcode] = SELECTEDVALUE(dim_organization[orgcode]), dim_calendar[year] = SELECTEDVALUE(dim_calendar[year]), FILTER ( fact_table, fact_table[verificationnumber] IN VALUES(fact_table[verificationnumber]) ) ), SELECTEDMEASURENAME() = "Budget", CALCULATE ( MAX(dim_links[URL]), dim_organization[orgcode] = SELECTEDVALUE(dim_organization[orgcode]), dim_calendar[year] = SELECTEDVALUE(dim_calendar[year]), FILTER ( fact_table, fact_table[verificationnumber] IN VALUES(fact_table[verificationnumber]) ) ), BLANK() ), CALCULATE ( MAX(dim_links[URL]), dim_organization[orgcode] = SELECTEDVALUE(dim_organization[orgcode]), dim_calendar[year] = SELECTEDVALUE(dim_calendar[year]), FILTER ( fact_table, fact_table[verificationnumber] IN VALUES(fact_table[verificationnumber]) ) ) ) )Did I answer your question? If so, please mark my post as the solution! ✔️
Your Kudos are much appreciated! Proud to be a Solution Supplier!- Mjolnir2 years ago
Helper I
Again, really appreciate your effort - though the problem still remained.
So the problem seemed to be related to the calculation item "Actuals", that returns blank when the selected measure name does not contain "actuals". So the Web URL measure was simply set to blank as its name does not contain "actuals" in it.
So I tried to to change the calculation item telling it to return the selected measure when the selected measure name either contain "Actuals" or "Web URL" - and it works now!
Calculation item changed to...
Actuals=IF (CONTAINSSTRING(SELECTEDMEASURENAME(), "Actuals") ||CONTAINSSTRING(SELECTEDMEASURENAME(), "Web URL"),SELECTEDMEASURE(),BLANK())