Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
I am getting below mentioned error with the following DAX statement:
An Argument of Function Date has wrong data type or result is too small or too large
Solved! Go to Solution.
Try this alternate
Sales Avg1 =
VAR EndD =
CALCULATE ( MINX ( Query2, Query2[DATE1] ) )
VAR StartD =
DATE ( YEAR ( EndD ) - 1, MONTH ( EndD ), DAY ( EndD ) )
RETURN
AVERAGEX (
FILTER ( Query1, Query1[Date] <= EndD && Query1[Date] >= StartD ),
Query1[Net_Revenue]
)
Try this alternate
Sales Avg1 =
VAR EndD =
CALCULATE ( MINX ( Query2, Query2[DATE1] ) )
VAR StartD =
DATE ( YEAR ( EndD ) - 1, MONTH ( EndD ), DAY ( EndD ) )
RETURN
AVERAGEX (
FILTER ( Query1, Query1[Date] <= EndD && Query1[Date] >= StartD ),
Query1[Net_Revenue]
)
This has worked!
Many thanks 🙂
The 2nd argument of FILTER must return a BOOLEAN expression (true or false)
DATESBETWEEN(Query1[Date],EndD,StartD) returns a date table
Thats why it throws an error
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.