Odoo Help


why OpenErp create some default field in postgresql database tables

Dasadiya Chaitanya
on 3/13/14, 7:56 AM 2,100 views

Can any one explain me why OpenErp Create some default in posgresql database table while creating a new object in OpneErp module ??

In a email_template module email.template object create some default field Like.. id,create_uid,create_date,write_date explain each field with description While from Openerp trunk-Server in base module like res_users and res_partner doen't created this kind of field in posgreSql database tables my question is why and and why not ??

Ray Carnes
On 3/16/14, 5:32 PM

id is added automatically to every model by OpenERP.

Every database requires a unique identified and OpenERP manages this via the id field and a related sequence.

The others are created for every model where self._log_access is set to True (which it is by default).

They are required if access rules are to be implemented for the model.

  • the user who created the record (create_uid)
  • the time it was created (create_date)
  • the user who last updated the record (write_uid)
  • the time it was last updated (write_date)

If a value for self._log_access is not specified, then you can prevent them from being created if self._auto is set to False

thanks Ray Carnes do u know why above fields is not used in base module for database table like res_users and res_partner as per my knowledge its default module in openerp therefore openerp doen't require this kind of fields

Dasadiya Chaitanya
on 3/18/14, 1:33 AM

About This Community

This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.


Odoo Training Center

Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.

Test it now

Question tools

1 follower(s)


Asked: 3/13/14, 7:56 AM
Seen: 2100 times
Last updated: 5/9/16, 12:48 AM