Click here to monitor SSC
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

datetime precision Expand / Collapse
Author
Message
Posted Friday, January 15, 2010 1:40 AM


Old Hand

Old HandOld HandOld HandOld HandOld HandOld HandOld HandOld Hand

Group: General Forum Members
Last Login: Monday, September 26, 2016 10:27 AM
Points: 309, Visits: 1,692
Comments posted to this topic are about the item datetime precision
Post #848125
Posted Wednesday, January 20, 2010 9:06 AM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Monday, September 10, 2012 5:20 PM
Points: 13, Visits: 94
Hi, This is great. We use the following constraint and sanitation before assignment on date only columns in SQL 2005:

check (dateAdd(dd, datediff(dd, 0, datetimeColumn), 0) = datetimeColumn)

I believe at least some of your wishes MS has implemented in SQL 2008. See here under embedded links: http://msdn.microsoft.com and here http://www.sql-server-performance.com.

The DATETIME function’s major change in SQL Server 2008 is the four DATETIME data types introduced. They are DATE, TIME, DATETIMEOFFSET and DATETIME2. IN addition to these newly introduced data types, there are new DATETIME functions all well.
Post #850572
Posted Thursday, May 19, 2016 1:27 PM
SSCrazy Eights

SSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy Eights

Group: General Forum Members
Last Login: Today @ 6:55 AM
Points: 8,101, Visits: 812
Thanks Bill, another good script.
Post #1787877
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse