Recently we needed to delete a custom related field, as it was slowing down Odoo to the point of the system being unusable.
What do we need to consider when creating related fields via the UI?
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
Recently we needed to delete a custom related field, as it was slowing down Odoo to the point of the system being unusable.
What do we need to consider when creating related fields via the UI?
Match the data type of the field you create to the field you are relating to. Don't create a Float related to an Int, for example.
Never create a related field based on (has a dependency of) a field that itself is related or computed.
If you don't need to store the value, don't.
Adding a stored related field on table where you already have thousands of records may not be possible, as values for all existing records need to be computed first, and you may get a timeout.
Make sure to avoid circular dependencies.
Review https://www.odoo.com/documentation/12.0/reference/orm.html#related-fields
Créez un compte dès aujourd'hui pour profiter de fonctionnalités exclusives et échanger avec notre formidable communauté !
S'inscrirePublications associées | Réponses | Vues | Activité | |
---|---|---|---|---|
|
5
août 24
|
3191 | ||
|
2
avr. 23
|
6380 | ||
|
0
janv. 22
|
2705 | ||
|
1
mars 25
|
4706 | ||
|
1
sept. 21
|
6368 |