Forum Discussion

AlineTCarvalho's avatar
AlineTCarvalho
New Member
2 years ago
Solved

CALENDARAUTO

Hello   I am trying to create a dCALENDAR with CALENDARAUTO, and my fiscal year starts in April, therefore April should be Q1 for instance. However when I use the QUARTER function, power bi unders...
  • lbendlin's avatar
    2 years ago

    "Quarter""Q" & QUARTER(EDATE([Date],3)))

  • Anonymous's avatar
    Anonymous
    2 years ago

    Hi AlineTCarvalho ,

     

    Thank lbendlin  very much for his solution! But there is a small error, it should be "Quarter""Q" & QUARTER(EDATE([Date],-3))). On that basis, I can give you a more complete date table, which can be seen in the following results:

    DimDate = 
    ADDCOLUMNS (
        CALENDARAUTO (),
        "Year", YEAR ( [Date] ),
        "Month", FORMAT ( [Date], "MMMM" ),
        "MonthSort", MONTH ( [Date] ),
        "Day", DAY ( [Date] ),
        "DayName", FORMAT ( [Date], "DDDD" ),
        "WeekDay", WEEKDAY ( [Date],2 ),
        "WeekStart",
            [Date] - WEEKDAY ( [Date], 2 ) + 1,
        "Quarter", "Q" & QUARTER(EDATE([Date],-3))
    )
    

     

    Hope it helps!

     

    Best regards,
    Community Support Team_ Scott Chang

     

    If this post helps then please consider Accept it as the solution to help the other members find it more quickly.