I have datecreated field in a table. It contains value as \"2009-12-30 11:47:20:297\" I have a query like this:
datecreated
select * from table where
You can use something like this with Sql Server
CREATE FUNCTION [dbo].[udf_DateOnly](@DateTime DATETIME) RETURNS DATETIME AS BEGIN RETURN DATEADD(dd,0, DATEDIFF(dd,0,@DateTime)) END
This line
DATEADD(dd,0, DATEDIFF(dd,0,@DateTime))
will strip out the Date portion.