I have noticed that when using the install feature this will add the row for the module/ocmod/ etc installation and that's Good and OK,
But I also noticed that If we Re-install the same for whatever the reason (normally an updated version) this will be created as a second Row in the table.
So understanding the visual logic created here:
The use have knowledge of the installation history as the dates and time will be different
The problem:
The user is able to Hit delete on a Previous installation and this will cause an issue as the same file/filepath are being use by the latest installed and these will be deleted
There will be an accumulation of records of the 3 used tables in the DB that is not being used by the system
Is there any known method (mysql trigger, php code) tested that solve this bad practice "issue" already ?
thanks.
Attachments
Screenshot 2023-04-06 at 11.58.04.jpg (101.5 KiB) Viewed 1598 times
Screenshot 2023-04-06 at 12.00.01.jpg (41.63 KiB) Viewed 1598 times
Screenshot 2023-04-06 at 12.00.49.jpg (93.82 KiB) Viewed 1598 times
OCMOD (in my opinion) best feature (above VQMOD) in that when you install it makes a record of all the files installed in the database and when you uninstall it, it removes all those files.
DISCLAIMER:
You should not modify core files .. if you would like to donate a cup of coffee I will write it in a modification for you.
https://www.youtube.com/watch?v=zXIxDoCRc84
Hi, Yes I do agree, but If you remove the old one, any conf you had will be lost so that's not ideal
Shouldn't be. Most config is held in the database and uninstalling will only remove the files. So when you reinstall then the settings should still all be there.
-
VIEW ALL EXTENSIONS * EXTENSION SUPPORT * WEBSITE * CUSTOM REQUESTS
NO OC VERSION
As grgr said, it should not be so. You will have to discuss that with the extension developer. Configs should not be effected. So either you did it wrong or the developer has used the wrong table in the database.
You already sent a screen shot .. extension install
DISCLAIMER:
You should not modify core files .. if you would like to donate a cup of coffee I will write it in a modification for you.
https://www.youtube.com/watch?v=zXIxDoCRc84
Yes I did but Upon Removing one row from it in the db.table, and refreshed the shop I could still look at it in the historyby mona wrote: ↑Thu Apr 06, 2023 11:20 pmNO OC VERSION
As grgr said, it should not be so. You will have to discuss that with the extension developer. Configs should not be effected. So either you did it wrong or the developer has used the wrong table in the database.
- Don't get me wrong, the OC VERSION is 3 as I am in the current forum, doesn't matter much which version of the 3 right? the DB still same structure.
You already sent a screen shot .. extension install
That is a good way to destroy your database. You can not (well you can obviously but it is not wise to) just delete a row in the database, other things are usually connected to it.
By this you mean the modification list (admin => extensions => modifications) ?
That would be the modification table
DISCLAIMER:
You should not modify core files .. if you would like to donate a cup of coffee I will write it in a modification for you.
https://www.youtube.com/watch?v=zXIxDoCRc84
Good Youtube videoby mona wrote: ↑Fri Apr 07, 2023 12:22 amThat is a good way to destroy your database. You can not (well you can obviously but it is not wise to) just delete a row in the database, other things are usually connected to it.
By this you mean the modification list (admin => extensions => modifications) ?
That would be the modification table

-
Cool - I have done a MySQL Trigger that solves this issue.
Thank you


Glad you have it sorted and thanks for adding [SOLVED]
DISCLAIMER:
You should not modify core files .. if you would like to donate a cup of coffee I will write it in a modification for you.
https://www.youtube.com/watch?v=zXIxDoCRc84
Users browsing this forum: No registered users and 2 guests