Solved

Transfer Database Task:  2000 to 2005, but no Primary Keys are copied - Help!!

Posted on 2007-03-22
7
638 Views
Last Modified: 2013-11-30
I am transferring a database from SQL Server 2000 to SQL Server 2005.  I am using 2005's Integration Services (SSIS) Transfer Database Task.  In this task, I am using the "DatabaseOnline" method.

The database transfer seemed to work, except no Primary Keys, Identity settings, Foreign Keys or Default Values transferred over!  

I have looked all over the property settings, and the internet, but I do not see any reference to including constraints.  How do I include PK, FK, etc., constraints when I use the Transfer Database Task to bring over an old SQL Server 2000 database to 2005?

0
Comment
Question by:jasonwisdom
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 2
7 Comments
 
LVL 11

Accepted Solution

by:
Ved Prakash Agrawal earned 250 total points
ID: 18772671
Hi,
Please try transfer SQL server object task which provide all the feature which you are looking for.
0
 
LVL 29

Expert Comment

by:Nightman
ID: 18772720
Best and most efficient way (while doing this online) is simply to take a new backup and restore this to the SQL 2005 server.

Remember to set the database compatibility level to 90 after the restore, and then updatestatistics.
0
 
LVL 1

Author Comment

by:jasonwisdom
ID: 18772912
Thank you, both.  

I am first trying the SQL Server Object Task - I'd like to keep this in a single IS package so others can just point & click & runi t.

But I'm getting an error, "Version80 database compatability level is not supported."

So far I hvaen't seen a property called Compatability Level or Version or anything like that.  Thoughts?

Thanks again.
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
LVL 29

Expert Comment

by:Nightman
ID: 18772971
Version 80 is SQL 2000. Version 90 is SQL 2005. It appears that the task cannot work against an SQL 2000 database.

Backup the database on SQL 2000 and then restore it on SQL 2005.
0
 
LVL 1

Author Comment

by:jasonwisdom
ID: 18773062
I got the compatability issue figured out, now I'm getting this message:

Error: 0xC002F325 at Transfer SQL Server Objects Task, Transfer SQL Server Objects Task: Execution failed with the following error: "ERROR : errorCode=-1073548784 description=Executing the query "DROP LOGIN [BUILTIN\Administrators]
" failed with the following error: "Cannot drop the login 'BUILTIN\Administrators', because it does not exist or you do not have permission.". Possible failure reasons: Problems with the query, "ResultSet" property not set correctly, parameters not set correctly, or connection not established correctly.
 helpFile= helpContext=0 idofInterfaceWithError={8BDFE893-E9D8-4D23-9739-DA807BCDC2AC}".
Task failed: Transfer SQL Server Objects Task


What...?????
I am switching to False every kind of login/permission setting I can find on the Properties.  So why is it trying to drop BUILTIN\Administrators??
0
 
LVL 1

Author Comment

by:jasonwisdom
ID: 18773084
Again, this is for the "Transfer SQL Server Objects Task".  
If I can swing this, I can get the entire database transfer into one single SSIS task.  That's my first choice.  It seems to go fairly far, except it's trying to drop logins.  

I fixed the compatability by right-clicking the 2005 Database in Management Studio, going to Properties, then Options, then chosing 9.0 for the 2005 database's compatability.  Fixed my one error.
0
 
LVL 1

Author Comment

by:jasonwisdom
ID: 18773526
OK, I figured it out.

Yes, I did use the "Copy SQL Server Objects Task".  However, I had to set about a dozen Properties.  I kept getting errors, dropping logins, creating logins, creating tables and stored procedures that already existed.....One key setting was "Copy Schema=false".

Anyway, it works.  I considered the backup / restore option, but going across versions has caused problems in the past - and it can't be automated into a simple, single SSIS task.

Thanks for your help.
0

Featured Post

Veeam gives away 10 full conference passes

Veeam is a VMworld 2017 US & Europe Platinum Sponsor. Enter the raffle to get the full conference pass. Pass includes the admission to all general and breakout sessions, VMware Hands-On Labs, Solutions Exchange, exclusive giveaways and the great VMworld Customer Appreciation Part

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

For both online and offline retail, the cross-channel business is the most recent pattern in the B2C trade space.
Ever wondered why sometimes your SQL Server is slow or unresponsive with connections spiking up but by the time you go in, all is well? The following article will show you how to install and configure a SQL job that will send you email alerts includ…
Viewers will learn how the fundamental information of how to create a table.
Viewers will learn how to use the SELECT statement in SQL to return specific rows and columns, with various degrees of sorting and limits in place.

626 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question