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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Syndicate_Admin
Administrator
Administrator

PowerQuery - Año de registro con M

Estoy buscando averiguar esto sobre cómo configurarlo, por lo que si las fechas de registro están entre el 3 de mayo de 2021 y el 3 de mayo de 2022, es FY22. Cualquier cosa después del 4 de mayo de 2022 y más allá es FY23

Table.AddColumn(#"Changed Type2", "Registration Year", each if [FirstNewDate] >= #datetime(2021, 5, 3, 0, 0, 0) then "FY22" else if [FirstNewDate] < #datetime(2022, 5, 3, 0, 0, 0) then "FY22" else if [FirstNewDate] >= #datetime(2022, 5, 4, 0, 0, 0) then "FY23" else "FY23"),

En lugar de poner para cualquier fecha pasada el 4 de mayo de 2022 como FY23, los enumera como FY22. ¿Alguna sugerencia sobre por qué está sucediendo esto?

¡Gracias!

2 REPLIES 2
Syndicate_Admin
Administrator
Administrator

@Vijay_A_Verma es por eso me encanta esta comunidad! :D. ¡Gracias que funcionó a las mil maravillas!

Syndicate_Admin
Administrator
Administrator

Usa esto

= Table.AddColumn(#"Changed Type", "Registration Year", each if Date.From([FirstNewDate])>=#date(2021,5,3) and Date.From([FirstNewDate])<=#date(2022,5,3) then "FY22" else "FY23")

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.

Top Solution Authors
Top Kudoed Authors