Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Get Fabric Certified for FREE during AI Skills Fest. This week only. Secure your voucher now.

Reply
Syndicate_Admin
Administrator
Administrator

Necesita ayuda con la funcionalidad de inteligencia de tiempo

Hola

Estoy creando una medida a través de la cual cualquier rango de fechas que se esté seleccionando en el filtro de fechas obtenga el año máximo para él y calcule el gasto para ese año para todos los Qtr de los cuales los datos están presentes.

Por favor, revise la siguiente medida que he creado y adjuntar y por favor sugiera el camino a seguir para ello. Necesito el gasto total para el año máximo sin tener en cuenta la fecha seleccionada en el filtro.

MaxyearAmount =

DÓNDE MAXyear =

CALCULAR( AÑO( MÁXIMO( 'Fecha'[DateValue] ) ), TODOSSELECCIONADOS() )

DÓNDE MinDate_MaxYear =

CALCULAR(

MIN( 'Fecha'[DateValue].[Año] ),

FILTRO( 'Fecha', 'Fecha'[Año] = MAXyear )

)

DÓNDE MaxDate_MaxYear =

CALCULAR(

MÁXIMO( 'Fecha'[DateValue].[Año] ),

FILTRO( 'Fecha', 'Fecha'[Año] = MAXyear )

)

DÓNDE MaxyearAmount =

CALCULAR(

[Gastar],

FILTRO(

'Fecha',

'Fecha'[DateValue].[Año] >= MinDate_MaxYear

&& 'Fecha'[DateValue].[Año] <= MaxDate_MaxYear

)

)

DEVOLUCIÓN
MaxyearAmount
Query.jpg
2 REPLIES 2
Syndicate_Admin
Administrator
Administrator

En ella, @laraibashfaq

Prueba algo como:

MaxyearAmount =
VAR MaxYear =
CALCULAR (
MAX ( 'Date'[DateValue] ),
ALLEXCEPT ( 'Date', 'Date'[DateValue] )
)
DEVOLUCIÓN
CALCULAR (
MAX ( [Gastar] ),
FILTRO (
ALLEXCEPT ( 'Date', 'Date'[DateValue] ),
'Date'[DateValue] = MaxYear
)
)

Nops, esta función no funciona

Helpful resources

Announcements
May Power BI Update Carousel

Power BI Monthly Update - May 2026

Check out the May 2026 Power BI update to learn about new features.

Fabric SQL PBI Data Days

Data Days 2026 coming soon!

Sign up to receive a private message when registration opens and key events begin.

New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Top Kudoed Authors