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.
Solved! Go to Solution.
Hi, @Anonymous
You can't Pass scalar value to STARTOFMONTH function you need to provide column name
Try below measure
CurrentMonthAverageYield =
VAR CurrentDate = MAX('calender yield'[Date])
var Monthstart = eomonth(today(),-1)+1
var MonthEnd = eomonth(today(),0)
RETURN
CALCULATE(
AVERAGE('Production orders'[Qty in kg]),
FILTER(
'calender yield',
'calender yield'[Date] >= Monthstart &&
'calender yield'[Date] <= MonthEnd
)
)
Hi, @Anonymous
You can't Pass scalar value to STARTOFMONTH function you need to provide column name
Try below measure
CurrentMonthAverageYield =
VAR CurrentDate = MAX('calender yield'[Date])
var Monthstart = eomonth(today(),-1)+1
var MonthEnd = eomonth(today(),0)
RETURN
CALCULATE(
AVERAGE('Production orders'[Qty in kg]),
FILTER(
'calender yield',
'calender yield'[Date] >= Monthstart &&
'calender yield'[Date] <= MonthEnd
)
)
Thank you so much!!!
User | Count |
---|---|
26 | |
12 | |
8 | |
8 | |
5 |
User | Count |
---|---|
28 | |
13 | |
12 | |
12 | |
6 |