Skip to main content
cancel
Showing results for 
Search instead 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.

Reply
bryanc78
Helper IV
Helper IV

Filtro de fecha relativa: ¿solución alternativa cuando se utiliza el campo de texto?

Tengo una tabla de calendario y quiero usar el campo de datos MonthYear en un gráfico de barras (septiembre de 2020) por lo que solo aparecen los últimos 3 meses. No quiero seguir cambiándolo manualmente cada mes, así que me gustaría usar un filtro de fecha relativa. El problema es que el campo de datos MonthYear de mi tabla de calendario es un campo de texto para que el filtro de fecha relativa no funcione.

El único campo de fecha en mi tabla de calendario es Fecha y que muestra los días, así como el mes y el año que no es lo que quiero.

¿Pensamientos?

3 REPLIES 3
v-jayw-msft
Community Support
Community Support

Hola @bryanc78 ,

Tiene columna de fecha (tipo de fecha) en la tabla de calendario, ¿verdad?

A continuación, debería poder usar la columna monthyear como eje y agregar la columna de fecha como filtro de fecha relativa.

1.PNG

¿Me perdí algo?

Saludos

Jay

Community Support Team _ Jay
If this post helps, then please consider Accept it as the solution
to help the other members find it.
amitchandak
Super User
Super User

@bryanc78 , Puede segmentar como esta y seleccionar el valor predeterminado

Tipo de mes : Switch( True(),
eomonth(Date[Date],0) á eomonth(Today(),0) ,"Current Month" , //This Month
eomonth(Date[Date],0) á eomonth(Today(),-1) ,"Previous Month" , //last Month
eomonth(Date[Date],0) á eomonth(Today(),1) ,"Next Month" , //last Month
[Año del mes]
)

O

Tipo de mes : Switch( True(),
eomonth(Date[Date],0) >- eomonth(Today(),-3)+1 && eomonth(Date[Date],0) <- eomonth(Today(),-0) ,"Last Three Month" ,
[Año del mes]
)

Greg_Deckler
Super User
Super User

@bryanc78 ¿Alguna posibilidad de que pueda usar cadenas de formato personalizado? https://docs.microsoft.com/en-us/power-bi/create-reports/desktop-custom-format-strings


@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

Helpful resources

Announcements
Microsoft Fabric Learn Together

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

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

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