Odoo Data Import
· Uncategorized
Please login to view the post
Troubleshooting Odoo System
Table of Contents
When do we import and when do we upgrade Odoo
Upgrading an Odoo database is the best:
- Brings over all data from the past to-date
When you cannot Upgrade, thus you can only import data one-at-a-time:
- Effort - Odoo recommends version by version update, example if you are using Odoo 15 and the current version, as of today is Odoo 18, you will need to upgrade from Odoo 15 > Odoo 16 > Odoo 17 > Odoo 18. While this is the recommended practice, but we have done one version direct to the final, from Odoo 15 to Odoo 18 directly
- Cost concerns - Moving from Odoo Community when you possibly have more than 5 users, and directly to Odoo Enterprise where each user are charged RM90/user/month, this adds up quite quickly
- Custom modules - Odoo Enterprise will help with changes done on Odoo Studio but once there are custom modules, Odoo Partners will have to do the upgrading. Concerns at a glance, involves field names and database changes
- Other concerns, of where software are heading in general - As software typically moves one version a year, so is Odoo. There are areas like apps Odoo and security as well. The general recommended practice:
- leverage as much as possible to configurations, Odoo has great out of the box routing that is able to accomodate small to medium enterprise
- sometime users have no ideas, their main concerns are stability of software. Thus in some cases they are willing to sacrifice ease-of-use versus stability
- Odoo Studio’s Server Actions and Automations can achieve some cases rather easily too.
Still thinking if a warehouse system , WMS, may work better for your company , please refer to our Guide to understand more about WMS
Which module to import first?
The following can be a starting Point:
- Always use EXTERNAL ID, this allows the Create/Update by default even when there is an error on updating. A mistake can be deleted and External ID remains Safe
- Contacts (Company) where “Is a Company” field is True
- Contacts (Individual) where Related Company /ID is used
- Sales Orders & Quotations - This can be ignored as we do not involve quotes in Accounting, Accounting is only concerned with Invoice, Expenses, Vendor Bills
- Invoices, where Contacts’ External ID are used
- All these modules should be Features you should be looking out for your WMS
Error: record base.user_admin res_partner has the module prefix base.
The record base.user_admin res_partner has the module prefix base. This is the part before the ’.’ in the external id. Because the prefix refers to an existing module, the record would be deleted when the module is upgraded. Use either no prefix and no dot or a prefix that isn’t an existing module. For example, __import__, resulting in the external id __import__.user_admin res_partner. at multiple rows
Initial Analysis
The Prefix “__export__.res_partner” be replaced with “res_partner”
The problem with replacing External ID
This will disrupt the keys being used in other modules, example Invoices will NOT be able to be linked back to the Original External ID of the contact after that. It will be extremely tedious to replace them later as some invoices are linked to Contacts (Individual) of the Contacts (Company)
Root Cause
Some base users (or internal users) are linked in the contacts, this is the ones causing the issue
Remedy:
Remove internal users in the CSV file of Contacts