• If you are using sql server edition higher than 2005 you can simply convert it to date datatype and it will return just the datepart

    select convert(date,'2010-09-23 13:02:54.000')

    else you will have to rely on those cumbersome string manipulations to get the datepart

    --------------------------------------------------------------------------------------------------
    I am just an another naive wannabe DBA trying to learn SQL Server