cancel
Showing results for
Did you mean:

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.

Regular Visitor

Hello power bi team,

Can you please give me some help on the following

I want to create a measure that calculates the total cost of the last day of the previous month of the previous year, but in the ENDOMONTH function more specifically in the DATEADD function, I get the error "A function DATEADD has been used in a True/False expression that is used as a table filter expression. This is not allowed".

How can I solve that?

1 ACCEPTED SOLUTION
Super User

=
CALCULATE (
[Costo Total],
'Dim Fecha'[Date] = EOMONTH ( 'Calidad Inventario'[Fecha Cargue], -12 ),
ALL ( 'Dim Fecha' )
)

2 REPLIES 2
Super User

=
CALCULATE (
[Costo Total],
'Dim Fecha'[Date] = EOMONTH ( 'Calidad Inventario'[Fecha Cargue], -12 ),
ALL ( 'Dim Fecha' )
)

Super User

=
CALCULATE (
[Costo Total],
'Dim Fecha'[Date] = EOMONTH ( 'Calidad Inventario'[Fecha Cargue], -12 ),
ALL ( 'Dim Fecha' )
)

Announcements

#### Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

#### Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

#### Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors
Top Kudoed Authors