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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
Anonymous
Not applicable

Line Chart

Hi,

 

I have the following as a measure:

Q1_T2B =
CALCULATE(
(CALCULATE(SUM(TABLE[wgt]),TABLE[Q1_Index]<3))
/
(CALCULATE(SUM(TABLE[wgt]),TABLE[Q1_Index]<5))
)
 
I've read and watched a lot of examples but most of them use date.  I've tried using some non-date solutions but when I put my wave in my x axis then nothing appears in the line chart.  I've tried many different things but can't seem to get anything to work.  Does anyone have any solutions I can try out?
 
Thanks!
1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @Anonymous ,

Please update the formula of your measure as below:

Q1_T2B =
VAR _selwave =
    SELECTEDVALUE ( 'TABLE'[WAVE] )
RETURN
    DIVIDE (
        CALCULATE ( SUM ( 'TABLE'[WEIGHTS] ), 'TABLE'[Q1_Index] < 3 ),
        CALCULATE (
            SUM ( 'TABLE'[WEIGHTS] ),
            FILTER (
                ALL ( 'TABLE' ),
                'TABLE'[Q1_Index] < 5
                    && 'TABLE'[WAVE] >= _selwave - 1
                    && 'TABLE'[WAVE] <= _selwave
            )
        ),
        0
    )

yingyinr_0-1616403492489.png

If the above one is not your expected result, please provide your expected result with samples and calculation logic base on current sample data. Thank you.

Best Regards

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

Hi @Anonymous ,

Please update the formula of your measure as below:

Q1_T2B =
VAR _selwave =
    SELECTEDVALUE ( 'TABLE'[WAVE] )
RETURN
    DIVIDE (
        CALCULATE ( SUM ( 'TABLE'[WEIGHTS] ), 'TABLE'[Q1_Index] < 3 ),
        CALCULATE (
            SUM ( 'TABLE'[WEIGHTS] ),
            FILTER (
                ALL ( 'TABLE' ),
                'TABLE'[Q1_Index] < 5
                    && 'TABLE'[WAVE] >= _selwave - 1
                    && 'TABLE'[WAVE] <= _selwave
            )
        ),
        0
    )

yingyinr_0-1616403492489.png

If the above one is not your expected result, please provide your expected result with samples and calculation logic base on current sample data. Thank you.

Best Regards

Anonymous
Not applicable

Hi @Anonymous 

 

How do I add ALLEXCEPT to the measure so that I can use filters with it?  I want to filter by GENDER for example

 

 

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

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.