Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 Import/Export (DTS) and Replication (2000)
 DTS file transfer

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2002-09-18 : 12:52:46
Dimitri writes "I use DTS (SQLSERver 2000 and W2k) to copy certain tables from a production server (sqlServer6.5) to a local database. I schedule the package to run every night. Basically I drop the tables on the local server and copy the fresh ones across. I experience problems when the production server is in the middle of a load. What happens is my local tables are dropped and then the package fails. So I have no data.
How do I check to see if the production server is ready for the copy before I drop the local tables?"

nr
SQLTeam MVY

12543 Posts

Posted - 2002-09-18 : 12:58:48
Instead of dropping them why not rename them (if you have space).

I guess you have some means of telling if the server is ready.
Call an SP at the begining of the package - or just use embedded sql if you dare to do whatever checks you need and terminate the package if the server isn't ready.

Alternatively you can lock a resource (dummy table to lock / table with a flag field) while the server is loading lock this resource and have something at the begining of the dts package to check it an wait.

Or put any of these checks as the first step of the job which schedules the transfer.

==========================================
Cursors are useful if you don't know sql.
DTS can be used in a similar way.
Beer is not cold and it isn't fizzy.

Edited by - nr on 09/18/2002 12:59:47
Go to Top of Page
   

- Advertisement -