TIP: You can type at any time to perform a new search.
Sparse Fields
base_sparse_field · odoo/odoo
- Repository
- odoo/odoo · module folder
- Module version
- 1.0
- Category
- Hidden
- Folder size
- 0.35 MB
- License
- LGPL-3
- Application
- No
- Auto-installable
- No
- Website
- None
- Last tracking update
- 2026-08-08 22:45:29
- Authors
- Odoo S.A.
- Maintainers
- Odoo S.A.
- Committers
- Xavier Morel, Odoo Translation Bot, Julien Castiaux, Achraf (abz), Tiffany Chang (tic), Gorash, Miquel Raïch, Dylan Kiss (dyki), Krzysztof Magusiak (krma)
- Odoo dependencies
-
odoo/odoo:- base
- Python dependencies
- None
- System dependencies
- None
- Required by
- attribute_set, edi_core_oca, fs_storage, queue_job, rpc_helper, server_environment, spreadsheet_oca
- Description
The purpose of this module is to implement "sparse" fields, i.e., fields that are mostly null. This implementation circumvents the PostgreSQL limitation on the number of columns in a table. The values of all sparse fields are stored in a "serialized" field in the form of a JSON mapping.
Code Analysis ⓘ
Views touched (2)
| XML ID | Name | Model | Type | Status |
|---|---|---|---|---|
field_form_view |
ir.model.fields | form | Inherits base.view_model_fields_form | |
model_form_view |
ir.model | form | Inherits base.view_model_form |
HTTP endpoints (0)
No HTTP endpoints found for this module.
Models touched (3)
New fields (0)
No new fields.
Public methods (0)No public methods.
New fields (2)
-
serialization_field_idMany2one → ir.model.fieldsdomain="[('ttype','=','serialized'), ('model_id', '=', model_id)]"help='If set, this field will be stored in the sparse structure of the serialization field, instead of having its own database column. This cannot be changed after creation.'ondelete='cascade'string='Serialization Field' args: 'ir.model.fields' -
ttypeSelectionondelete={'serialized': 'cascade'}selection_add=[('serialized', 'serialized')]
-
write(self, vals)
New fields (7)
-
booleanBooleansparse='data' -
charCharsparse='data' -
dataSerialized -
floatFloatsparse='data' -
integerIntegersparse='data' -
partnerMany2one → res.partnersparse='data' args: 'res.partner' -
selectionSelectionsparse='data' args: [('one', 'One'), ('two', 'Two')]
No public methods.
Loading…
Loading…
Loading…
Loading…
Loading…
Loading…
Loading…
Loading…