Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
harib
Post Patron
Post Patron

How to get aggregated value if no value selected from slicer

Hello Friends

 

How to get aggregated value if no value selected from slicer. I want the output like below image. In slicer there are 3 values. if i dont select value from slicer output should com like Mark 2. I mean aggregated value show come.If  it's possible kindly describe how to achive .

1.PNG

Thanks

1 ACCEPTED SOLUTION

I would say based on your explanation that you could tackle is by using an if statement in the measure, like mentioned before. 

View solution in original post

5 REPLIES 5
DouweMeer
Post Prodigy
Post Prodigy

What you have to do is create a measure as you request a different scalar value based on a change in context in the dashboard.

What you can do is create another table with you column values. Then use it as a filter in your dashboard. Following is adding a measure with:

if ( hasonevalue ( new table ) , "column" , "Mark2" )

It roughly works on the same principe as a dynamic axis. 

https://www.youtube.com/watch?v=n-OWNaCUU0o

@DouweMeer 

Why rows are incresing when we go for unpivot as i shown in the picture. In the real time senario if we have 1,00,000 rows and when we go for unpivot based on the unpivot column values it's multiplying the rows . Then we may get performance issue right

 

ex : In my picture before unpivot table has 4 rows and when i unpivot 3 columns these 4 rows are increased upto 12 rows becasue of 3 columns like (Column A, Column B, Column C ). 

 

Can anyone clarify on this

 

Thanks

Well, that is how an unpivot works. If you unpivot them all at once, you get 1 column stuffing all data in separate rows. 3 columns x 4 rows becomes 1 column x 12 rows.

Else you would loose data.

But I've done that with my dataset as well. Just have 2 tables instead and tie them to a unique key in the main table. 1 new table that is unpivotted with no extra information and the other tables, the main table, with all additional information. This way you don't duplicate unnecessary.

 

 

@DouweMeer 

 

That's fine ,i also did the samething, but i want to get the aggregated value when we dont select any values from the slicer.Is it possible. 

 

Thanks 

I would say based on your explanation that you could tackle is by using an if statement in the measure, like mentioned before. 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.