Odoo Help

Welcome!

This community 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.

0

Updating modules. Bad query - null value in column "user_type"

By
Miguel Fernández
on 12/13/13, 7:22 AM 1,404 views

Hi.

I get the error below after update modules with bazaar and update the database of OpenERP with the new modules.

Anybody knows what can I do?

...
2013-12-13 10:56:47,788 3658 INFO copia_gf openerp.addons.base.ir.ir_model: Deleting 2252@account.account.template
2013-12-13 10:56:47,810 3658 INFO copia_gf openerp.addons.base.ir.ir_model: Deleting 29@account.account.type
2013-12-13 10:56:47,812 3658 ERROR copia_gf openerp.sql_db: bad query: delete from account_account_type where id IN (29)
Traceback (most recent call last):
          File "/opt/openerp/server/openerp/sql_db.py", line 226, in execute
            res = self._obj.execute(query, params)
    IntegrityError: null value in column "user_type" violates not-null constraint
    CONTEXT:  SQL statement "UPDATE ONLY "public"."account_account_template" SET "user_type" = NULL WHERE $1 OPERATOR(pg_catalog.=) "user_type""
...

On upgrade, some code is attempting to delete record from account_account_type with id=29 but that is been referenced in account_account_template and it is mandatory.

akram
on 12/16/13, 10:31 PM

I update modules with bazaar again and all was ok. Aparently there is a bug with the registers update during upgrade of modules.

Miguel Fernández
on 12/17/13, 5:45 AM

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

1 follower(s)

Stats

Asked: 12/13/13, 7:22 AM
Seen: 1404 times
Last updated: 3/16/15, 8:10 AM