DNN Forums

Ask questions about your website to get help learning DNN and help resolve issues.

Uninstalling a module and Uninstall sql script

 4 Replies
 0 Subscribed to this topic
 26 Subscribed to this forum
Sort:
Author
Messages
Ana
New Around Here
Posts: 0
New Around Here

I am trying to uninstall a custom module that we created. When I uninstall the module, it is deleting tables that are in the module along with some other tables in database not connected to this custom module. I thought deleting Uninstall.SqlDataProvider from the module folder will stop from running the Uninstall.SqlDataProvider script when I uninstall the module, but it is still deleting the tables along with unconnected tables. Looks like Uninstall.SqlDataProvider script is either saved somewhere in the database or files. Where does DNN save it? I am thinking that this saved version has some errors that was erronously deleting unconnected tables. Please help.

Growing Member
Posts: 55
Growing Member
MVP
MVP
You're an MVP!
Is it possible to upload a new "version" of the module as well? Maybe that can include a corrected uninstall script? You might also simply be able to modify the manifest/module registration to remove that SQL reference.

I can't find anywhere that DNN might be storing the script on the file system, though I feel like I've recently seen that it does store the ZIP files somewhere after a module is installed.

Ana
New Around Here
Posts: 0
New Around Here
The issue is resolved now. In case any one is wondering, the issue was couple of our custom modules are missing "basePath" value for script files in the dnn file, which caused the sql script files to be copied to base DNN folder instead of respective module folders and the last module that was installed has it uninstall sql script in the base DNN folder and when I uninstalled the module it was running the unistall script of the last module that was installed with the basePath issue. I tried changing the "manifest" column data (in packages table) directly in the database, but it didn't work for some reason. I had to install a update to the module that I was planning to uninstall with correct basePath so that it can run the correct uninstall script when I uninstalled it.
Growing Member
Posts: 55
Growing Member
MVP
MVP
You're an MVP!
Awesome followup!
Senior Member
Posts: 1322
Senior Member
3 Helpful Replier
Helpful Replier
Thanks for being such a helpful replier!
Lifesaver
Lifesaver
You're Life Saver!
New Poster
New Poster
Congrats on posting!
3 Engaged Reader
Engaged Reader
You are an engaged reader!

Agreed!

These Forums are for the discussion of the open source CMS DNN platform and ecosystem.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. If you have (suspected) security issues, please DO NOT post them in the forums but instead follow the official DNN security policy
  2. No Advertising. This includes the promotion of commercial and non-commercial products or services which are not directly related to DNN.
  3. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  4. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  5. No Flaming or Trolling.
  6. No Profanity, Racism, or Prejudice.
  7. Site Moderators have the final word on approving / removing a thread or post or comment.
  8. English language posting only, please.

Would you like to help us?

Awesome! Simply post in the forums using the link below and we'll get you started.

Get Involved