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
Syndicate_Admin
Administrator
Administrator

Número de semana personalizado

hola
Quiero crear una columna de semana personalizada para mi ejercicio (agosto a julio).
El año fiscal 2019 es del 1 de agosto de 2019 al 31 de julio de 2020
El año fiscal 2020 es del 1 de agosto de 2020 al 31 de julio de 2021
El primero de agosto es el primer día de la semana. La segunda semana comienza el 8 de agosto y así sucesivamente...
Ayúdame a crear una columna.
Gracias de antemano.

1 ACCEPTED SOLUTION
Syndicate_Admin
Administrator
Administrator

@bharathsurya ,

Probar columnas como

Date = CALENDAR(date(2014,01,01),date(2020,12,31))
Week Start Date with Year = var _1 =QUOTIENT(DATEDIFF(STARTOFYEAR('Date'[Date],"7/31"),'Date'[Date],DAY),7) return STARTOFYEAR('Date'[Date]) + if(_1<52,_1,51)*7
Week No = var _1=  QUOTIENT(DATEDIFF(STARTOFYEAR('Date'[Date],"7/31"),'Date'[Date],DAY),7)+1 return if(_1<52,_1,52)
Week Day = MOD(DATEDIFF('Date'[Week Start Date with Year],[Date],DAY),7)+1

View solution in original post

1 REPLY 1
Syndicate_Admin
Administrator
Administrator

@bharathsurya ,

Probar columnas como

Date = CALENDAR(date(2014,01,01),date(2020,12,31))
Week Start Date with Year = var _1 =QUOTIENT(DATEDIFF(STARTOFYEAR('Date'[Date],"7/31"),'Date'[Date],DAY),7) return STARTOFYEAR('Date'[Date]) + if(_1<52,_1,51)*7
Week No = var _1=  QUOTIENT(DATEDIFF(STARTOFYEAR('Date'[Date],"7/31"),'Date'[Date],DAY),7)+1 return if(_1<52,_1,52)
Week Day = MOD(DATEDIFF('Date'[Week Start Date with Year],[Date],DAY),7)+1

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.