Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi all, in below chart I have the total sales per office for a timeframe of 3 months:
along with this chart I also have a slicer that adjusts the timeframe to specific date ranges.
I need to add a chart that indicates the average sales per day per office, and that also can be adjusted with the slicer.
How can I do this?
@Josuep Well, let's say your measure is "Sales", you could do this:
Average Sales Per Day Measure =
VAR __MinDate = MIN('Dates'[Date])
VAR __MaxDate = MAX('Dates'[Date])
VAR __Days = ( __MaxDate - __MinDate ) * 1.
VAR __Sales = [Sales]
VAR __Result = DIVIDE( __Sales, __Days, 0)
RETURN
__Result
Hi Greg,
thanks for your reply, I tried it but the formula is failing on this line: VAR _Sales = [Sales]. I presume this is because Sales is not a measure but a column in my data base. How can I solve this?
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.