The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hi all,
I have a value set in a measure for Allocated Hours. I am looking to subtract the Total Hours column (as filtered by a slicer) from that value but it keeps telling me the table / column are not found? Any help would be appreciated.
Solved! Go to Solution.
You need to wrap Table1[Total Hours] in an aggregate function such as SUM. I would create the measure below, and then the New Balance measure can be [Allocated Hours] - [Total Hours].
Total Hours = SUM ( Table1[Total Hours] )
Proud to be a Super User!
You can use the CALCULATE function to control filter context. I prefer to keep base measures free of filters so they can be used as building blocks for other measures. Thus, you could have a measure like this:
Total Hours Filtered = CALCULATE ( [Total Hours], FilterCondition1, FilterCondition2 )
Proud to be a Super User!
Total Hours = SUM ( Table1[Total Hours] )
Is there a way to fileter the above so that if only sums certain values / ros in the Total Hours column?
You can use the CALCULATE function to control filter context. I prefer to keep base measures free of filters so they can be used as building blocks for other measures. Thus, you could have a measure like this:
Total Hours Filtered = CALCULATE ( [Total Hours], FilterCondition1, FilterCondition2 )
Proud to be a Super User!
Thanks for the help - very much appreciated.
You need to wrap Table1[Total Hours] in an aggregate function such as SUM. I would create the measure below, and then the New Balance measure can be [Allocated Hours] - [Total Hours].
Total Hours = SUM ( Table1[Total Hours] )
Proud to be a Super User!
Excellent - worked a treat - thank you