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.
I have a Measure totaling sales within a given month. It looks something like this:
Solved! Go to Solution.
@Anonymous , Try like
Sales Dollars = CALCULATE(SUM(Sales[Dollars]), Filter(Sales, EOMONTH(Sales[SaleDate],0) = EOMONTH(TODAY(),0)))
if this works, refer
http://dataap.org/blog/2019/04/22/difference-between-calculate-with-and-without-filter-expression/
@Anonymous , Try like
Sales Dollars = CALCULATE(SUM(Sales[Dollars]), Filter(Sales, EOMONTH(Sales[SaleDate],0) = EOMONTH(TODAY(),0)))
if this works, refer
http://dataap.org/blog/2019/04/22/difference-between-calculate-with-and-without-filter-expression/
So, the moral of the story is never, ever use the "filter" parameters of CALCULATE, just use the FILTER function within a CALCULATE. Man, that's a dangerous pitfall to just throw in people's way.
Anyway, thanks for the clarification. Switching to using FILTER() got rid of this behavior.