Results 1 to 4 of 4

Thread: Capitalisation

  1. #1
    Join Date
    Jul 2003
    Posts
    2

    Unanswered: Capitalisation

    Hi Guys

    Anybody tell me where of if there is a setting to set
    whether or not the fields and table names need to be case
    specific on SQL 2000.

    I've been using SQL Server 7 where it has not been the case that the table and field names had had to be the same capitalisation-wise in running.

    ie select * from tbl_example would work if the table name was Tbl_Example

    I've just been trying to run the same queries on a different
    server, which is running SQL 2000, and they won't execute unless the
    capitalisation on the table and field names are exactly
    the same.

    There must be a simple setting somewhere please!

  2. #2
    Join Date
    Jun 2003
    Location
    Ohio
    Posts
    149

    Re: Capitalisation

    You must change the collation settings. To change one or more of these settings, you must rebuild the master and user databases.

    How to rebuild the master database (Rebuild Master utility)
    To rebuild the master database

    Shutdown Microsoft® SQL Server™ 2000, and then run Rebuildm.exe. This is located in the Program Files\Microsoft SQL Server\80\Tools\Binn directory.


    In the Rebuild Master dialog box, click Browse.


    In the Browse for Folder dialog box, select the \Data folder on the SQL Server 2000 compact disc or in the shared network directory from which SQL Server 2000 was installed, and then click OK.


    Click Settings. In the Collation Settings dialog box, verify or change settings used for the master database and all other databases.
    Initially, the default collation settings are shown, but these may not match the collation selected during setup. You can select the same settings used during setup or select new collation settings. When done, click OK.

    In the Rebuild Master dialog box, click Rebuild to start the process.
    The Rebuild Master utility reinstalls the master database.

    Note To continue, you may need to stop a server that is running.

    Needless to say, you have to be extremely careful if you are trying to re-build your master or user databases. So I would suggest you do it only if it is abosolutely necessary. Refer to BOL for more information.

    All the best




    Originally posted by garethimh
    Hi Guys

    Anybody tell me where of if there is a setting to set
    whether or not the fields and table names need to be case
    specific on SQL 2000.

    I've been using SQL Server 7 where it has not been the case that the table and field names had had to be the same capitalisation-wise in running.

    ie select * from tbl_example would work if the table name was Tbl_Example

    I've just been trying to run the same queries on a different
    server, which is running SQL 2000, and they won't execute unless the
    capitalisation on the table and field names are exactly
    the same.

    There must be a simple setting somewhere please!

  3. #3
    Join Date
    Jul 2003
    Posts
    2

    Re: Capitalisation

    Originally posted by sbaru
    You must change the collation settings. To change one or more of these settings, you must rebuild the master and user databases.

    How to rebuild the master database (Rebuild Master utility)
    To rebuild the master database

    Shutdown Microsoft® SQL Server™ 2000, and then run Rebuildm.exe. This is located in the Program Files\Microsoft SQL Server\80\Tools\Binn directory.


    In the Rebuild Master dialog box, click Browse.


    In the Browse for Folder dialog box, select the \Data folder on the SQL Server 2000 compact disc or in the shared network directory from which SQL Server 2000 was installed, and then click OK.


    Click Settings. In the Collation Settings dialog box, verify or change settings used for the master database and all other databases.
    Initially, the default collation settings are shown, but these may not match the collation selected during setup. You can select the same settings used during setup or select new collation settings. When done, click OK.

    In the Rebuild Master dialog box, click Rebuild to start the process.
    The Rebuild Master utility reinstalls the master database.

    Note To continue, you may need to stop a server that is running.

    Needless to say, you have to be extremely careful if you are trying to re-build your master or user databases. So I would suggest you do it only if it is abosolutely necessary. Refer to BOL for more information.

    All the best
    Brilliant, thanks!

  4. #4
    Join Date
    Feb 2002
    Location
    Houston, TX
    Posts
    809
    sbaru's suggetion is dead on but remember to make a backup of everything first.
    Paul Young
    (Knowledge is power! Get some!)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •