• Philip, It uses less CPU, but it has rounding issues just like all the other "Cast(Cast(@date as int) as datetime)". Any time over 12 Noon and the day is rounded up.

    However...

    cast(substring(cast(@date as binary(8)),1,4) + 0x00000000 as datetime)

    ...Has no rounding issues at all.

    And, as long as you put your code in a function and use it consistently, conversion shouldn't be an issue if Microsoft decides to change their date formats.

    Signature is NULL