Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 

Content with tag DateTime Rss

   Items 1 to 20 of 27    Older >>
 

Finding “Active” Rows for the Previous Month (SQL Spackle)

SQL Server MVP Jeff Moden walks us through the classic problem of finding all the "Active" rows for the previous month using start and end dates. This is excellent for those new to T-SQL.  Read more...
By Jeff Moden 2014/01/30 | Source: SQLServerCentral.com | Category: t-sql
Rating: |  Discuss |   Briefcase | 6,132 reads

Calculating Duration Using DATETIME Start and End Dates (SQL Spackle)

It's an old problem with a solution that's nearly as old. SQL Server MVP Jeff Moden shows us the old trick mixed with a slick trick to format the duration as extended hours, minutes, seconds, and milliseconds.   Read more...
By Jeff Moden 2014/01/16 | Source: SQLServerCentral.com | Category: t-sql
Rating: |  Discuss |   Briefcase | 10,593 reads

Datetime conversion of empty string

By Gabe Tower 2013/11/25 | Category: datetime
Rating: (not yet rated) |  Discuss |   Briefcase | 2,113 reads

Function to format a datetime variable by a mask

I have used the following function to convert dates according to desired textual formats that were not immediately available in the standard styles on offer.  Read more...
By Colin Frame 2013/10/18 | Source: SQLServerCentral.com | Category: datetime
Rating: |  Discuss |   Briefcase | 1,552 reads

Date and Time dimension creation and population T-SQL

Dim_Date and Dim_Time. Date and Time dimensions. Creation, population with holidays, indexing and use script.  Read more...
By Joshua A. Walker 2013/10/04 | Source: SQLServerCentral.com | Category: data warehousing
Rating: |  Discuss |   Briefcase | 22,746 reads

DATETIME - 4

By bitbucket-25253 2013/03/18 | Category: datetime
Rating: (not yet rated) |  Discuss |   Briefcase | 1,951 reads

DATETIME - 3

By bitbucket-25253 2013/03/11 | Category: datetime
Rating: (not yet rated) |  Discuss |   Briefcase | 1,856 reads

Converting to datetime a char field with several possible date formats

Converting to datetime a char field having several possible date formats  Read more...
By Federico Iori 2013/02/21 | Source: SQLServerCentral.com | Category: t-sql
Rating: |  Discuss |   Briefcase | 1,484 reads

DATETIME 2

By bitbucket-25253 2012/08/02 | Category: datetime
Rating: (not yet rated) |  Discuss |   Briefcase | 2,692 reads

DATETIME 1

By bitbucket-25253 2011/12/07 | Category: datetime
Rating: (not yet rated) |  Discuss |   Briefcase | 2,244 reads

TSQL fast unix timestamp conversion

How to convert Unix timestamp into datetime taking into account also summer or winter time  Read more...
By Federico Iori 2011/12/02 | Source: SQLServerCentral.com | Category: timestamp
Rating: |  Discuss |   Briefcase | 446 reads

DateTime Comparison

By jkelly 2011/11/28 | Category: datetime
Rating: (not yet rated) |  Discuss |   Briefcase | 2,669 reads

Use of DATETIME and BETWEEN - Part 2

By Dwayne Dibley 2011/11/18 | Category: datetime
Rating: (not yet rated) |  Discuss |   Briefcase | 2,862 reads

Use of BETWEEN and DATETIME

By Dwayne Dibley 2011/09/27 | Category: datetime
Rating: (not yet rated) |  Discuss |   Briefcase | 2,696 reads

Get DATE part of the DATETIME

A quick and elegant way to obtain date part of the datetime values  Read more...
By Jano Petras 2011/06/14 | Source: SQLServerCentral.com | Category: datetime
Rating: |  Discuss |   Briefcase | 5,783 reads

Functions for using the keys from the Date and Time Dimensions

Three functions for obtaining the date and time dimension keys with a date or the date from the keys  Read more...
By Joshua A. Walker 2011/05/03 | Source: SQLServerCentral.com | Category: data warehousing
Rating: |  Discuss |   Briefcase | 4,219 reads

Date and Time dimension creation and population T-SQL

Dim_Date and Dim_Time. Date and Time dimensions. Creation, population with holidays, indexing and use script.  Read more...
By Joshua A. Walker 2013/10/04 | Source: SQLServerCentral.com | Category: data warehousing
Rating: |  Discuss |   Briefcase | 22,746 reads

How long has passed since SQL Server service started?

Days, hours and minutes since SQL Server service was started  Read more...
By Lars Søe Mikkelsen 2010/11/05 | Source: SQLServerCentral.com | Category: getdate()
Rating: |  Discuss |   Briefcase | 2,266 reads

How long has passed since SQL Server service started?

Days, hours and minutes since SQL Server service was started  Read more...
By Lars Søe Mikkelsen 2010/11/05 | Source: SQLServerCentral.com | Category: getdate()
Rating: |  Discuss |   Briefcase | 2,266 reads

datetime precision

Accuracy and precision go hand-in-hand. This script helps trim date values to whatever size is stored in a table's column.  Read more...
By William Talada 2010/01/20 | Source: SQLServerCentral.com | Category: datetime
Rating: |  Discuss |   Briefcase | 1,085 reads
   Items 1 to 20 of 27    Older >>
 
Tags
t-sql (12)    
date manipulation (7)    
convert (3)    
function (3)    
cast (2)    
data warehousing (2)    
datawarehouse (2)    
dimensions (2)    
between (1)    
case (1)    
converter (1)    
date (1)    
datediff (1)    
datepart (1)    
duration (1)    
format (1)    
getdate() (1)    
len() (1)    
mask (1)    
precision (1)    
sql spackle (1)    
string (1)    
substring (1)    
summer time (1)    
timestamp (1)    
unix (1)