Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes! Register now.
Hi,
I need to create a measure to divide the num days of a month/NUMBER OF DAYS WITH SALES DATA, ir order to calculate a closing estimate. Fe: November has 30 days and I know the sales for the fisrt 15 days (30/15) end finally I multiply by the monthly total sales... (total number of days of the month/number of days I have sales)*total sales of the current month.
Any idea?
Thanks so much
Solved! Go to Solution.
Tough to be specific here without sample data but perhaps something along the lines of:
Sales Data = CALCULATE(SUM(Sales[Sales]),FILTER(Sales,[Sales]<>BLANK()))
?
Thank you very much for your help. I have adapted the measurements and clues that you have given me and, after several attempts, it is already working
Measure:
Estimated Sales at EOM =
VAR DaysWithSales=distinctcount('sales'[date])
VAR DaysInMonth = distinctcount('datetable'[date])
RETURN
SUM('sales'[salesamount])/
DIVIDE(DaysWithSales,DaysinMonth,0)
I think something like this would work if you have a date table linked to your sales table. If you then create a table where the month/year is a dimension, it should calculate it correctly.
Tough to be specific here without sample data but perhaps something along the lines of:
Sales Data = CALCULATE(SUM(Sales[Sales]),FILTER(Sales,[Sales]<>BLANK()))
?
Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!
Check out the September 2025 Power BI update to learn about new features.