Question

I am using MS SQL Server Management Studio Express. I have installed "MyDatabase.msi" in my machine.So "Mydatabase" database have created with tables in MS SQL Server Management Studio Express automatically after the installation.It was working fine.yesterday I have uninsatlled the "MYDatabase.msi" from control panel,But the database and tables are still in MS SQl Server Management Studio Express.Why it is not removed? I want to remove the database while uninstall process. So how to do that?

Was it helpful?

Solution

UIninstall won't automatically remove the tables and data you added to a db on the system. If you wrote code to add that data then you need to write code to delete it.

I can't tell from your post if the db file is being physically left behind on the system too. If it is, I suspect you created it from scratch in the app or with code doing the install. Either way, if you create it then you need to remove it. Uninstall will not remove that db file unless it was installed as a file by the MSI like your other files were. So you can add it to your setup and populate it with your code, then uninstall will delete it, or add an uninstall custom action to remove it or depopulate or whatever it you want to do about it.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top