all groups > sql server dts > august 2005 >
You're in the

sql server dts

group:

Export to Access Database


Export to Access Database Jason
8/21/2005 12:00:00 AM
sql server dts: I have created a package that just export a number of tables to an Access
Database and it works fine.

However, when I rerun the package, I get error message as it cannot create
the tables (This is because they are already exists in the Access database).

What is a better way for me to handle this problem ?

A fellow has suggested creating an 'execute SQL task', that checks for the
existence of the table first, and drops it if needed. However, I don't know
how to create that task, is it possible to give me some advice ?

Thanks

Re: Export to Access Database Allan Mitchell
8/21/2005 7:42:01 AM
Are you using the wizard or are you using a package?

If the former then in the wizard there is an option to turn off the
"Recreate" functionality. If the latter then have a look at the package and
find the step that does the CREATE of the tables and remove it.

Sure you could look to DROP and then CREATE the tables but that would mean
you transfer all rows again all the time basically destroying any work you
have done in Access. This may or may not be acceptable.

Allan


[quoted text, click to view]

Re: Export to Access Database Jason
8/24/2005 12:00:00 AM
Dear Allan,

I find that the "Drop and Recreate Table" option is in the Transformation
button. I have re-created the DTS package with wizard. It runs with error
the first time (There is nothing to drop) but it works fine when I re-run
it.

Thanks
Jason

[quoted text, click to view]

Re: Export to Access Database Allan Mitchell
8/24/2005 7:59:22 PM
Correct that is exactly what it will do. Are you saving the package? If
you are then open up the package and remove the step that does the drop.

Allan


[quoted text, click to view]

AddThis Social Bookmark Button