DNN Forums

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

Uninstalling a module and Uninstall sql script

Sort:
You are not authorized to post a reply.





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





      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.

      Chris Hammond Christoc.com Software Solutions
      With DNN since before it was DNN!
      Open Source Projects and Tutorials since 2003





      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





          Awesome followup!
          Chris Hammond Christoc.com Software Solutions
          With DNN since before it was DNN!
          Open Source Projects and Tutorials since 2003





          Veteran Member





          You are not authorized to post a reply.

          These Forums are dedicated to the discussion of DNN Platform.

          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