Fixing Collation in 2005

  • The databases were created in the default collation of the server then scripts were run to create the tables we needed problem was we specified collation. So now I have a db in one collation and table in the db in a different collation I know I must create another db and move the data but need help in doing this in SQL 2005.

    I have learned my lesson I may still create tables using scripts but will not specify collation anymore.

     

    Any help in this would be greatly appreciated 

     

    --Robert--

  • Hi Robert

     

    It is possible to change the collation of the tables you have already created using the ALTER TABLE statement. Keep in mind however that you will probably need to specify the new collation type for each and every char, varchar or text column.

     

    The safest way forward would probably be to remove the COLLATE clause from your script and create a new DB using this script.  You can then simply transfer the data from the old to the new database using the Import and Export wizard.

Viewing 2 posts - 1 through 1 (of 1 total)

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