Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 Site Related Forums
 Article Discussion
 Article: Using the DATE data type in SQL Server 2008

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2007-12-06 : 08:27:34

In SQL Server 2008 we get a new DATE date type that allows you to store a
date without a time.



Read Using the DATE data type in SQL Server 2008

henrikop
Constraint Violating Yak Guru

280 Posts

Posted - 2007-12-06 : 09:04:32
Good article. Simple and does the job. I'd like to add something of value here, but there's nothing I can think of.

Henri
~~~~
There's no place like 127.0.0.1
Go to Top of Page

easyrider
Starting Member

3 Posts

Posted - 2007-12-07 : 04:24:04
Great no more remove (9,2) or storing dates as varchar, or whatever other bodge jobs I have used in the past.
Shame most of my customers are still using SQL2000 though. What can we do about that ?

Simon
Go to Top of Page

kunaaldesai
Starting Member

36 Posts

Posted - 2009-07-26 : 22:10:43
Guys I am still wondering that if I want the date format to be declared as MM/DD/YYYY instead of YYYY-MM-DD.

I mean to say that if I declare any of the data type to be the date then is there any was that I can make MM/DD/YYYY default instead of current?

Kunal
Go to Top of Page

khtan
In (Som, Ni, Yak)

17689 Posts

Posted - 2009-07-26 : 22:14:52
That is formatting issue, nothing to do with how the date is stored in the database.

You can use convert() to format the date or perform the formatting on your front end application.


KH
[spoiler]Time is always against us[/spoiler]

Go to Top of Page

kunaaldesai
Starting Member

36 Posts

Posted - 2009-07-26 : 22:59:43
Thanks again KH I will consider it.
Go to Top of Page

JJ123
Starting Member

1 Post

Posted - 2011-08-24 : 19:15:53
My agency recently upgraded to SQL Server 2008 R2 and I immediately began taking advantage of the Date datatype. However, my front-end application, MS Access 2003 does not seem to recognize the date datatype. Access treats the date datatype as 'text'. Any thoughts on what to do? Do I have to find all the 'date' fields and convert back to datetime? Thanks.
Go to Top of Page
   

- Advertisement -