Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

current date format.

Status
Not open for further replies.

beechill4

Technical User
May 10, 2005
207
IE
Hi,

I have 3 questions with regard to date formats and sql server:

1. how can i check what the current date format setting is:
2. how can i change the date format setting
3. can the date format be different for each database on a sql server?

Thanks in advance,
J
 
Can you be specific. If you are trying to enter the value to a Field you might need to format the data format, datetime,smalldatetime.

Dr.Sql
Good Luck.
 
Hi,

sorry for the vague-ness of my post.

I want to load csv files into a database but i do not know what the default is for the date fields in my database.

someone has just mentioned to me that this is determined at the OS level?
 
Datetime and smalldatetime datatypes are not stored in any 'recognizable' format in the database. They are stored as two 4-byte values. It is how they are DISPLAYed that is the issue. The default is the OS format, however you can CONVERT to whatever format you desire.

Check out FAQ183-5834 and FAQ183-5842.

-SQLBill

Posting advice: FAQ481-4875
 
What type of format you have in your CSV. 1-1-2005,1/1/2005 both formats should be able export without any issues.

Dr.Sql
Good Luck.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top