Solved

ASP.NET / SQL Server Express Locale / Date format settings

Posted on 2008-06-22
2
848 Views
Last Modified: 2013-11-07
We recently migrated servers and on the new server ASP.NET websites are displaying the time format incorrectly.

Not sure if this is a result of .NET settings or SQL Server settings, but basically any website using ASP.NET / SQL Server (Express) is displaying the date format as: MM-DD-YYYY.

However it should be using the DD-MM-YYYY setting instead. In the server's control panel regional settings, this has been setup.

Wondering if the .NET framework or SQL Server maintain their own locale settings somewhere and if so, where can I find these settings (I've looked but been unable to find it).

Also, SQL server is currently running as the "Local System" account, if that makes any difference.
0
Comment
Question by:bradderick
2 Comments
 
LVL 5

Accepted Solution

by:
JuckMan earned 500 total points
ID: 21843393
it depend on where you are reading the datetime values from using .net method calls like Datetime.now or from the database.
If it is from database then use the following article to figure out what your current settings are and how to change it to a different one
http://www.karaszi.com/SQLServer/info_datetime.asp

hope this helps
0
 

Author Comment

by:bradderick
ID: 21843415
It's happening to values from the database - and on the old server this was fine.

Which is why I suspect maybe locale settings need to be changed in SQL server - but haven't been able to find where to do it from.

Note the server's locale settings (specified in the windows control panel) seem to be ignored by SQL server.
0

Featured Post

Zoho SalesIQ

Hassle-free live chat software re-imagined for business growth. 2 users, always free.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Ever needed a SQL 2008 Database replicated/mirrored/log shipped on another server but you can't take the downtime inflicted by initial snapshot or disconnect while T-logs are restored or mirror applied? You can use SQL Server Initialize from Backup…
Via a live example combined with referencing Books Online, show some of the information that can be extracted from the Catalog Views in SQL Server.
Viewers will learn how to use the INSERT statement to insert data into their tables. It will also introduce the NULL statement, to show them what happens when no value is giving for any given column.

895 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now