Change Collation of the Model DB (SQL 2005)

SQL 2005I need to change the collation of tempdb, since it's created as new every time SQL Server restart copying the configuration of model DB, I must change the Model DB Collation.

When you try to change it into SQL 2005, you get the error:
Cannot alter the database 'model' because it is a system database. (Microsoft SQL Server, Error: 3708)

This occur because all system databases (including model and tempdb) must have the same collation as master. Mmmmmmm to change tempdb, I must change model, but to change model, I've to change master !!

In earlier version the REBUILDM.EXE could do thework well, how can I do it in SQL 2005 ?

Step 1. Put SQL Server into Single User Mode (use “sqlserver.exe -m” )
Step 2. Rebuild the system databases (start /wait setup.exe /q INSTANCENAME= REINSTALL=SQL_Engine REBUILDDATABASE=1 SAPWD=MyPWD SQLCOLLATION=MyCollation )
Step 3. Restart the SQL Server Services in regular mode

Before do it, read here:
http://msdn2.microsoft.com/en-us/library/ms179254.aspx !!!
Share on Google Plus

About Vittorio Pavesi

    Blogger Comment
    Facebook Comment

0 commenti: