Pro SQL Server 2005 a nižší:
CONVERT(varchar(8), @ParamDate, 112) -- Supported way
CAST(FLOOR(CAST(@ParamDate AS float)) AS DATETIME) -- Unsupported way
Pro SQL Server 2008 a vyšší:
CAST(@ParamDate AS DATE)
Pro SQL Server 2005 a nižší:
CONVERT(varchar(8), @ParamDate, 112) -- Supported way
CAST(FLOOR(CAST(@ParamDate AS float)) AS DATETIME) -- Unsupported way
Pro SQL Server 2008 a vyšší:
CAST(@ParamDate AS DATE)