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

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
Clint
Helper V
Helper V

Boolean calculations and filters

Hello,
 
I'm trying to write a measure to sum the max possible score for a set of entries in the table based on a SNo of 25 thru 59.  The following measure looks like it should do this from a logical stand point but I get the following error when applying it to a card visual.  MaxiumScore is a field type of whole number as is SNo.
 
M_FC Max Score = CALCULATE(Sum(QPlanCurrent[MaximumScore]),'Qplancurrent'[Sno]>=25<=59)
 
BI error.PNG
1 ACCEPTED SOLUTION
Anonymous
Not applicable

Just noticed, what if you try this:

M_FC Max Score = 
CALCULATE(
    SUM ( QPlanCurrent[MaximumScore] ),
    AND(
        'Qplancurrent'[Sno]>=25,
        'Qplancurrent'[Sno]<=59)
)

View solution in original post

4 REPLIES 4
Anonymous
Not applicable

Be sure to check the those columns, the Max score and the Sno. I'd load them into Power Query, explicitly set the data types and see if there are any errors. Usually things like this happen when there one or just a few rows where a text field, blank, or some thing weird got in there.

Hey Nick,

 

There are errors in the columns for sure but this measure does work

M_Rel Start Max Score = CALCULATE(Sum(QPlanCurrent[MaximumScore]),'Qplancurrent'[Sno]<=24)
 
Anonymous
Not applicable

Just noticed, what if you try this:

M_FC Max Score = 
CALCULATE(
    SUM ( QPlanCurrent[MaximumScore] ),
    AND(
        'Qplancurrent'[Sno]>=25,
        'Qplancurrent'[Sno]<=59)
)

Thanks so much Nick.  The last paren wasn't necessary.  Once I removed it, it worked perfectly and returned the expected Value.  

Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

LearnSurvey

Fabric certifications survey

Certification feedback opportunity for the community.