Date setting

  • Hi all,

    I'm new here.

    How to change "internal" setting of Date in SQL Server 7/2000?

    I would like it to be "Australian" date like '23-12-2001' when I issue Insert/Update statement rather than '12-23-2001'?

    many thanks,

    anthony

  • This is how to change the default language of the SQL Server from BOL:

    How to set the default language (Enterprise Manager)

    To set the default language

    Expand a server group.

    Right-click a server, and then click Properties.

    Click the Server Settings tab.

    In the Default language for user box, choose the language in which Microsoft® SQL Server™ should display system messages.

    The default language is English.

    And I believe British is what you will want to use.

    "Don't roll your eyes at me. I will tape them in place." (Teacher on Boston Public)

  • hi Antares686,

    I've change the language setting to 'british english' and restart the service, but when I try this command:

    use northwind

    insert into orders (orderdate) values ('20-12-2001')

    I got error message like:

    Server: Msg 242, Level 16, State 3, Line 1

    The conversion of a char data type to a datetime data type....

    but when I change the query statement like

    insert into orders (orderdate) values ('10-12-2001')

    it works fine. that meant the date format is still in American format!

    or did I miss something?

    thanks for your help,

    anthony

  • In 2000, I believe this is also stored at the database and table level. You might need to rebuild the table.

    In EM, if you go to the table, right click, choose design and then pick the column, at the bottom you will see a collation item. I think this needs to change as well.

    Steve Jones

    steve@dkranch.net

  • Hi Steve,

    I'm lost. I heard about collation code, new stuff since 2000? I'm not sure what it is, what it is for. can anyone give me enlighten pls?

    Which system table I have to change? is it better to re-install sql server?

    many thanks,

    anthony

  • The collation is the code page and sort order used for the table. This affects storage and display. In older versions of sql, there was a single code page and sort order for the server. With SQL 2000 (maybe 7), you can set this separately for each database and each table. This is useful for hosting different types of databases. Not sure if you can change the db once it's created. You may need to create a new database and set the australian code page you need. Not sure which one this would be.

    Steve Jones

    steve@dkranch.net

Viewing 6 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic. Login to reply