• In the DateAdd function, third parameter is date. 2nd parameter is the increment.

    When you write DATEADD(d,0,getdate())

    0 days are added to current date.

    When you write DATEADD(d, DATEDIFF(d, 0, @Today), 0);

    the date here is 0, select cast(0 as datetime) -- 1900-01-01 00:00:00.000

    I'm not sure what you are trying to achieve here.

    https://sqlroadie.com/