| Author |
Message |
cbondeson
Joined: 29 Nov 2005 Posts: 7
|
Posted: Tue Apr 15, 2008 7:14 pm Post subject: Reinstall Database |
|
|
This is an unusual circumstance but would like to hear a suggestion.
Run .net application which installs named instance of SQL Express 2005,
creates database using comand line envokation of SQL Packager 5, sets up users/logins/schemas/permissions...
Uninstall this app without deleting the database.
Try to reinstall->fails because mdb file exists.
Since the mdb is not attached why doesn't SQL Packager just overwrite it?
I understand the solution would be to just test for the file in the app but we use a generic named SQL Packager exe to create different databases. |
|
| Back to top |
|
 |
Brian Donahue
Joined: 23 Aug 2004 Posts: 6345 Location: Red Gate Software
|
Posted: Fri Apr 18, 2008 3:21 pm Post subject: |
|
|
Hi Carl,
SQL Packager simply creates SQL Scripts for the schema and data of a database, so it's not concerned with the state of the server. What is probably happening is that you are specifying the /makedatabase switch on the package which is going to try to create the database again.
To avoid this, you could use SQL Packager's /presql command to run a script file containing 'drop database [x]' before running the package. Hopefully this solves the problem for you. _________________ Brian Donahue
Technical Support
Red Gate Software Ltd.
44 (0)870 160 0037 ext 8521
US and CAN 1-866-RED GATE ext 8521 |
|
| Back to top |
|
 |
|
|
All times are GMT + 1 Hour
|
| Page 1 of 1 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group