From: CKKwan on
Dear All,

I am accessing Sql Server using C#, System.Data.SqlClient.

Problem with DateTime. When the server is located in different part of
the world it uses different culture and display DateTime in different
format.

Besides, the First Day of a week is also different.

So, may I know how can I get the Culture Info of the server?

Thanks in advance :)
From: Aaron Bertrand [SQL Server MVP] on
While a session can override it, a quick way to check is:

DBCC USEROPTIONS;


On 6/26/08 11:18 PM, in article
447f1e4a-8f0b-4239-8adb-27bc47ea9def(a)c19g2000prf.googlegroups.com, "CKKwan"
<ckkwan(a)my-deja.com> wrote:

> Dear All,
>
> I am accessing Sql Server using C#, System.Data.SqlClient.
>
> Problem with DateTime. When the server is located in different part of
> the world it uses different culture and display DateTime in different
> format.
>
> Besides, the First Day of a week is also different.
>
> So, may I know how can I get the Culture Info of the server?
>
> Thanks in advance :)

From: Ekrem Önsoy on
You may want to SET LANGUAGE to a specific language you use. For example,
SET LANGUAGE TURKISH would change the date format to d\m\y and some other
settings to this language's format...

You can list the system languages in SQL Server using sys.syslanguages
system table. There, you'll find the formats of listed languages.

For more information about SET LANGUAGE:
http://msdn.microsoft.com/en-us/library/ms174398.aspx

You'll also want to take a look at SET DATEFORMAT. This will change the way
you enter date info to your SQL Server databases.
http://msdn.microsoft.com/en-us/library/ms189491.aspx

--
Ekrem �nsoy



"CKKwan" <ckkwan(a)my-deja.com> wrote in message
news:447f1e4a-8f0b-4239-8adb-27bc47ea9def(a)c19g2000prf.googlegroups.com...
> Dear All,
>
> I am accessing Sql Server using C#, System.Data.SqlClient.
>
> Problem with DateTime. When the server is located in different part of
> the world it uses different culture and display DateTime in different
> format.
>
> Besides, the First Day of a week is also different.
>
> So, may I know how can I get the Culture Info of the server?
>
> Thanks in advance :)