dbTalk Databases Forums  

Is There A Way

microsoft.public.sqlserver.dts microsoft.public.sqlserver.dts


Discuss Is There A Way in the microsoft.public.sqlserver.dts forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Wayne Wengert
 
Posts: n/a

Default Is There A Way - 08-03-2004 , 06:08 AM






I have a production SQL Server (2000) that includes quite a few tables that
include FKs pointing to various other tables. Those FKs are defined with
referential integrity enabled. For example, I have a master "Names" table
which has information on individuals. I have another table "Suppliers" that
includes an FK field ("Contact") pointing to an entry in the "Names" table.

I've been testing a new structure on a different SQL Server and many tables
have had fields add, renamed, re-sized, etc. I want to replace the tables on
the production system with the new versions. I was going to simply delete
all the tables that will be changed from the production server and then use
DTS to transfer the new versions. The problem is that any table that has the
data linked to by the FKs in other tables cannot be deleted.

How can I accomplish this.

Wayne



Reply With Quote
  #2  
Old   
Darren Green
 
Posts: n/a

Default Re: Is There A Way - 08-03-2004 , 05:31 PM






In message <OuB4$nUeEHA.3476 (AT) tk2msftngp13 (DOT) phx.gbl>, Wayne Wengert
<wayneDONTWANTSPAM (AT) wengert (DOT) com> writes
Quote:
I have a production SQL Server (2000) that includes quite a few tables that
include FKs pointing to various other tables. Those FKs are defined with
referential integrity enabled. For example, I have a master "Names" table
which has information on individuals. I have another table "Suppliers" that
includes an FK field ("Contact") pointing to an entry in the "Names" table.

I've been testing a new structure on a different SQL Server and many tables
have had fields add, renamed, re-sized, etc. I want to replace the tables on
the production system with the new versions. I was going to simply delete
all the tables that will be changed from the production server and then use
DTS to transfer the new versions. The problem is that any table that has the
data linked to by the FKs in other tables cannot be deleted.

How can I accomplish this.

Wayne

Script off the constraints, as drops and creates. Run drops, do the DTS
stuff, run the create script. Probably a clever way of doing if you
don't have them, but we always have scripts created to do the job as it
is how we do change control and such like.

--
Darren Green (SQL Server MVP)
DTS - http://www.sqldts.com

PASS - the definitive, global community for SQL Server professionals
http://www.sqlpass.org



Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.