[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

IIS and MSSQL dates using hidden default locale setting on Windows Server 2003?

Posted on 2007-10-01
4
Medium Priority
?
1,071 Views
Last Modified: 2008-09-17
So, this is an old problem but I would love to get to the bottom of it's cause, rather than the workaround...

I have an ASP.NET site which uses a MSSQL 2000 database.  On one web server, it displays everything correctly with UK date formats dd/mm/yyyy as expected throughout the whole site.  But on another server (Windows Server 2003), any query that returns dates, comes back in US format mm/dd/yyyy.  The MSSQL server is the same in both cases.

Now I know I can put LCID=2057 in each of the pages of the site to combat this issue but I would really love to know what needs to be set on the server to enable everything to run in UK format by default.

All the regional setting in Control Panel are set to UK.... what's going on?  Is there a hidden default locale setting in the IIS metabase or something?

Help appreciated...
0
Comment
Question by:jammy-d0dger
2 Comments
 
LVL 5

Accepted Solution

by:
kmotaweh earned 1000 total points
ID: 19996470
the iisdiag tool from microsoft.com will tell what is hapening and how to solve it
0
 
LVL 37

Assisted Solution

by:samtran0331
samtran0331 earned 1000 total points
ID: 20141579
not sure if you consider it a "workaround"...but you should be able to set the locale in the web.config file...which should override any server settings...

<configuration>
 <system.web>
  <globalization
    requestencoding="utf-8"
    responseencoding=" utf-8"
    fileencoding=" utf-8"
    culture="en-GB"
    uiculture="en-GB" />
 </system.web>
</configuration>
0

Featured Post

Prepare for your VMware VCP6-DCV exam.

Josh Coen and Jason Langer have prepared the latest edition of VCP study guide. Both authors have been working in the IT field for more than a decade, and both hold VMware certifications. This 163-page guide covers all 10 of the exam blueprint sections.

Question has a verified solution.

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

As tax season makes its return, so does the increase in cyber crime and tax refund phishing that comes with it
A phishing scam that claims a recipient’s credit card details have been “suspended” is the latest trend in spoof emails.
Screencast - Getting to Know the Pipeline
With just a little bit of  SQL and VBA, many doors open to cool things like synchronize a list box to display data relevant to other information on a form.  If you have never written code or looked at an SQL statement before, no problem! ...  give i…
Suggested Courses

872 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