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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
stefanjt
Frequent Visitor

Calculation Group in Card (new) Visual - Display Dynamic Storage Units

Dear Community,

 

I need to show dynamic storage units based on a slicer selection (bytes, kilobytes, megabytes, gigabytes and terabytes) for "cold storage", "hot storage" and "total storage". I have created the 3 measures + the calculation group which dynamically converts the selected measure to the correct storage unit. I am displaying it correctly in a matrix visual, however I also need to make the units dynamically change in a Card (new) visual.

 

Here's my setup:

1. Database usage table:

stefanjt_0-1725707054969.png

2. Storage units table

stefanjt_1-1725707157311.png

3. Measures

Total cold storage = 
SUM(
    'Database usage'[Cold storage]
)


Total hot storage = 
SUM(
    'Database usage'[Hot Storage]
)


Total storage = 
[Total cold storage] + [Total hot storage]

 

4. Calculation group with this item:

Storage unit = 
VAR converted_storage =  
DIVIDE(
    SELECTEDMEASURE(),
    POWER(
        1024,
        SELECTEDVALUE(
            'Storage units'[ID],
            0
        )
    )
)

RETURN
FORMAT(
    converted_storage,
    "0,0.00 " &
    SELECTEDVALUE(
        'Storage units'[Storage unit]
    )
)

5. Visuals: 

stefanjt_2-1725707570613.png

I need help setting up the Card (new) visual so that it dynamically changes the storage units based on the selection from the slicer.

 

Any suggestions?

 

I am attaching a sample report: https://www.dropbox.com/scl/fi/49nnz5sqglay3v5iwgukp/Storage-Units-Demo-Calculation-Groups.pbix?rlke... 

 

Thank you in advance!

1 ACCEPTED SOLUTION
tharunkumarRTK
Super User
Super User

@stefanjt 

You just need to add a visual level filter, Darg the calculation group column into the filters pane on the right and select the calculation item name: 

 for the new scorecard visual:

Screenshot 2024-09-07 at 6.33.50 PM.png

Screenshot 2024-09-07 at 6.35.49 PM.png

 

I am attaching the pbix file for your reference 

Need a Power BI Consultation? Hire me on Upwork

 

 

 

Connect on LinkedIn

 

 

 








Did I answer your question? Mark my post as a solution!
If I helped you, click on the Thumbs Up to give Kudos.

Proud to be a Super User!


PBI_SuperUser_Rank@2x.png

 

View solution in original post

2 REPLIES 2
tharunkumarRTK
Super User
Super User

@stefanjt 

You just need to add a visual level filter, Darg the calculation group column into the filters pane on the right and select the calculation item name: 

 for the new scorecard visual:

Screenshot 2024-09-07 at 6.33.50 PM.png

Screenshot 2024-09-07 at 6.35.49 PM.png

 

I am attaching the pbix file for your reference 

Need a Power BI Consultation? Hire me on Upwork

 

 

 

Connect on LinkedIn

 

 

 








Did I answer your question? Mark my post as a solution!
If I helped you, click on the Thumbs Up to give Kudos.

Proud to be a Super User!


PBI_SuperUser_Rank@2x.png

 

@tharunkumarRTK,

 

Thank you so much, that worked!

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.