Click here to monitor SSC
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 

Get your favorite SSC scripts directly in SSMS with the free SQL Scripts addin. Search for scripts directly from SSMS, and instantly access any saved scripts in your SSC briefcase from the favorites tab.
Download now (direct download link)

Restore 2000 DB to 2005

By David A. Long,

This script was designed to restore a backup of a SQL Server 2000 database from disk file to SQL Server 2005.

Unfortunatelly the RESTORE will leave land mines for you to find the hard way, this script was updated to fix all that I have found:

Change CONCAT_NULL_YIELDS_NULL ON, PAGE_VERIFY CHECKSUM, Compatibility level to 90, remove the database role and user schema creation, and reassign the user's schema to dbo.

Like the ealier RestoreDB script posted here, this version will handle multiple DB files, move the files to new location, with new database name that is customized for the date of the backup, create any missing logins, and fix any user accounts that are orphaned by differing SIDs from the other server.

Total article views: 4461 | Views in the last 30 days: 16
 
Related Articles
ARTICLE

Scripting SQL Server databases with SMO using EnforceScriptingOptions

Obscure impact of switch EnforceScriptingOptions to scripting a SQL Server database.

FORUM

Script all Stored procs for all databases on a server

script all stored procs for all databases on a server

FORUM

how get generate script for database user with their database and server roles

how get generate script for database user with their database and server roles

SCRIPT

Script to change auto growth settings for all databases in SQL Server

Script to change auto growth settings for all databases in SQL Server.

FORUM

I need script related to databases

glnp scripts on database

Tags
backup and restore    
t-sql    
 
Contribute