Menu

What does uninstalling an Odoo module really delete? I measured it for CRM
📰

What does uninstalling an Odoo module really delete? I measured it for CRM

DEV Community: postgres·Mehedi Hassan Shifat·5 days ago
#zbjLIV0Q
#devtopostgresql#devto#dev#apps#database
Reading 0:00
15s threshold

The uninstall button warns you about dependent apps and nothing else. So I took a demo database, wrote down what I expected to be removed, uninstalled CRM, and compared the database before and after.

Disclosure: I make a paid Odoo module that previews this (link at the bottom). The numbers below don't depend on it.

CRM takes 5 other modules with it (6 in total). The database loses 32 tables and 31 columns from other tables, and 286 records go with them, leads included.

The rule Odoo follows: everything the modules own through an external ID is deleted, unless a module that stays also owns it. Models lose their tables, fields their columns, and selection values that records still use are a problem on their own.

I turned that into a module. It computes the list and shows it before you click, and I checked its numbers against a real uninstall: modules, tables, columns and record counts all matched.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.