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

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
RoshanK
Helper II
Helper II

Calculate Volume Share ( when filter is coming from a table)

Hi,

I have 3 tables - Calendar, Dimension & Fact table. I have 2 measures:- Volume = SUM(Sales[Volume]) & 

Volume Share =
DIVIDE(
    [Volume],
    CALCULATE(
        [Volume],
        ALLSELECTED(Dim),
        ALLSELECTED(Sales)
    ))

 

I am using Volume Share measure in a table & line chart in a same page. I want to modify this measure such that when a user selects Product A, I want the line chart to show same value as when nothing is selected. Please refer to image.

 

RoshanK_0-1689344135989.png

Any guidance will be appreciated!

Thanks in advance!

4 REPLIES 4
RoshanK
Helper II
Helper II

Hi again,

 

This logic that I derived from your measure works 😃

I think there is another simple way to do it but unless I can figure it out. This is fine. Refer to picture:

RoshanK_0-1689412858302.png

 

This works in test file but not in real. I must be missing something!

BeaBF
Super User
Super User

@RoshanK Hi!
Try with something like:
Volume Share Modified =
IF (
ISFILTERED ( Dim[Product] ),
DIVIDE ( [Volume], [Volume], 1 ),
DIVIDE (
[Volume],
CALCULATE ( [Volume], ALLSELECTED ( Dim ), ALLSELECTED ( Sales ) )
)
)

BBF

Hi @BeaBF

 

This doesn't work. Based on your measure, the line chart shows the same 100% value for all or no selection.

RoshanK_0-1689409776289.png

 

Thanks!

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

Jan25PBI_Carousel

Power BI Monthly Update - January 2025

Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.

Jan NL Carousel

Fabric Community Update - January 2025

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