Forum Discussion
vengadesh_p
Helper II
3 years agoNeed help to create ISO WEEK, ISO Month, ISO YEAR Logic
Hello Everyone I need help to create dax for ISO Month I have created dax for Normal Week | Month | Year ,"Week No",WEEKNUM([Date],2)
,"Month",MONTH([Date])
,"Year",YEAR([Date]) also i ...
- 3 years ago
based on week start date i created ISO Month & ISO Year
,"Week No",WEEKNUM([Date],2) ,"Week Start Date",[Date]-WEEKDAY([Date],2)+1 ,"Week End Date",[Date]+7-WEEKDAY([Date],2) ,"Year Week Number", COMBINEVALUES("-",YEAR([Date]),FORMAT( WEEKNUM([Date]),"00")) ,"ISO Week",WEEKNUM([Date],21) ,"ISO Month", Month ([Date] - WEEKDAY([Date],2) + 1) ,"ISO Year", Year ([Date] - WEEKDAY([Date],2) + 1) ,"ISO Year Week Number", COMBINEVALUES("-", Year ([Date] - WEEKDAY([Date],2) + 1),FORMAT( WEEKNUM([Date],21),"00")) ,"ISO Quarter", if (Month ([Date] - WEEKDAY([Date],2) + 1) <=3, 1, if (Month ([Date] - WEEKDAY([Date],2) + 1) <=6 , 2, if (Month ([Date] - WEEKDAY([Date],2) + 1) <=9 , 3, if (Month ([Date] - WEEKDAY([Date],2) + 1) <=12 , 4))))
vengadesh_p
Helper II
3 years agobased on week start date i created ISO Month & ISO Year
,"Week No",WEEKNUM([Date],2)
,"Week Start Date",[Date]-WEEKDAY([Date],2)+1
,"Week End Date",[Date]+7-WEEKDAY([Date],2)
,"Year Week Number", COMBINEVALUES("-",YEAR([Date]),FORMAT( WEEKNUM([Date]),"00"))
,"ISO Week",WEEKNUM([Date],21)
,"ISO Month", Month ([Date] - WEEKDAY([Date],2) + 1)
,"ISO Year", Year ([Date] - WEEKDAY([Date],2) + 1)
,"ISO Year Week Number", COMBINEVALUES("-", Year ([Date] - WEEKDAY([Date],2) + 1),FORMAT( WEEKNUM([Date],21),"00"))
,"ISO Quarter", if (Month ([Date] - WEEKDAY([Date],2) + 1) <=3, 1,
if (Month ([Date] - WEEKDAY([Date],2) + 1) <=6 , 2,
if (Month ([Date] - WEEKDAY([Date],2) + 1) <=9 , 3,
if (Month ([Date] - WEEKDAY([Date],2) + 1) <=12 , 4))))