DECLARE @DATE DATETIME SET @DATE = GETDATE() SELECT DATE...

0

Please login or register to vote for this query.

(click on this box to dismiss)

Sports

Q&A for participants in team and individual sport activities

-- Enter Query Title
-- Enter Query Description
    DECLARE @DATE DATETIME
    SET @DATE = GETDATE()
    
    SELECT DATEPART(dy, @DATE) AS DayOfYear
        , DATEDIFF(d, DATEADD(qq, DATEDIFF(qq, 0, @DATE), 0), @DATE) + 1 AS DayOfQuarter
        , DAY(@Date) AS DayOfMonth
        , DATEPART(dw, @DATE) AS DayOfWeek

Enter Parameters

Options:
Switch sites:
loading Hold tight while we fetch your results