SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Restore databse from SQL SERVER 2005 to SQL SERVER 2012.


Restore databse from SQL SERVER 2005 to SQL SERVER 2012.

Author
Message
vinod.venugopal 71189
vinod.venugopal 71189
SSC Rookie
SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)

Group: General Forum Members
Points: 34 Visits: 2
Hi,

We are in planning phase to migrate our current databases from SQL Server 2005 (SP3 + CU6) to SQL SERVER 2012.Will their be any issue if we take the backup and restore it to the new environmnet(SQL 2012).
Is it necessary to apply SP4 on SQL Server 2005 before we plan to migrate.

Thanks in advance.

Regards,
--Vinod
Lowell
Lowell
SSC Guru
SSC Guru (75K reputation)SSC Guru (75K reputation)SSC Guru (75K reputation)SSC Guru (75K reputation)SSC Guru (75K reputation)SSC Guru (75K reputation)SSC Guru (75K reputation)SSC Guru (75K reputation)

Group: General Forum Members
Points: 75531 Visits: 40987
it is not necessary to upgrade, no; the database backup is the same, regardless of service pack, version, and that's what you would backup/restore. the service packs / CU change how the engine behaves, and not how the backup is stored.

one thing i'd mention is to make sure you update statistics; the stats are used differently between engine versions, and not updating statistics often leads to reports of "the new super server with 40 petabytes of RAM is slower than the old server" until that is done.

something like this is what i've suggested int eh past:

DECLARE @Exec VARCHAR(MAX)
SELECT @Exec = ''
SELECT @Exec = 'UPDATE STATISTICS '
+ QUOTENAME(schema_name(schema_id))
+ '.'
+ quotename(name)
+ ' WITH FULLSCAN ; '
+ CHAR(13)
+ CHAR(10) + @Exec FROM sys.tables ORDER BY name DESC
PRINT LEN(@Exec)
PRINT @Exec
EXEC(@Exec)



Lowell
--help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!
rocks
rocks
SSC Veteran
SSC Veteran (209 reputation)SSC Veteran (209 reputation)SSC Veteran (209 reputation)SSC Veteran (209 reputation)SSC Veteran (209 reputation)SSC Veteran (209 reputation)SSC Veteran (209 reputation)SSC Veteran (209 reputation)

Group: General Forum Members
Points: 209 Visits: 461
we also perform same and may be you want to update your view , below is the script.

DECLARE @view AS VARCHAR(255) ;

DECLARE ListOfViews CURSOR FOR

SELECT TABLE_SCHEMA + '.' +TABLE_NAME FROM INFORMATION_SCHEMA.TABLES
WHERE TABLE_TYPE = 'VIEW'
AND OBJECTPROPERTY(OBJECT_ID(TABLE_NAME), 'IsMsShipped') = 0
ORDER BY TABLE_SCHEMA,TABLE_NAME
OPEN ListOfViews
FETCH NEXT FROM ListOfViews
into @view
WHILE (@@FETCH_STATUS <> -1)
BEGIN FETCH NEXT FROM ListOfViews
INTO @view
BEGIN TRY
EXEC sp_refreshview @view;
PRINT @view;
END TRY
BEGIN CATCH
PRINT 'recorded error in this refreshView on : ' + @view;
END CATCH;
FETCH NEXT FROM ListOfViews
INTO @view
END
CLOSE ListOfViews;

DEALLOCATE ListOfViews;
MANU-J.
MANU-J.
SSCertifiable
SSCertifiable (7.6K reputation)SSCertifiable (7.6K reputation)SSCertifiable (7.6K reputation)SSCertifiable (7.6K reputation)SSCertifiable (7.6K reputation)SSCertifiable (7.6K reputation)SSCertifiable (7.6K reputation)SSCertifiable (7.6K reputation)

Group: General Forum Members
Points: 7624 Visits: 8766
Thanks for sharing the script guys.
vinod.venugopal 71189
vinod.venugopal 71189
SSC Rookie
SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)

Group: General Forum Members
Points: 34 Visits: 2
I thought SQL Server 2005 has to be on SP4 or above before we plan to migrate/restore it to SQL 2012.

Thanks for clarifying my doubt. I will also definitely consider using above scripts.

--Vinod
Lowell
Lowell
SSC Guru
SSC Guru (75K reputation)SSC Guru (75K reputation)SSC Guru (75K reputation)SSC Guru (75K reputation)SSC Guru (75K reputation)SSC Guru (75K reputation)SSC Guru (75K reputation)SSC Guru (75K reputation)

Group: General Forum Members
Points: 75531 Visits: 40987
vinod.venugopal 71189 (7/9/2013)
I thought SQL Server 2005 has to be on SP4 or above before we plan to migrate/restore it to SQL 2012.

Thanks for clarifying my doubt. I will also definitely consider using above scripts.

--Vinod


i think that might be true for an in place upgrade, but when just doing backup and restore on the new 2012, then it's not necessary

Lowell
--help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search