1
votes

In invoice when i'm trying to register a payment this error message shows up :

The operation cannot be completed, probably due to the following:

  • deletion: you may be trying to delete a record while other records still reference it

  • creation/update: a mandatory field is not correctly set [object with reference: name - name]

I cheked the access rights but nothing, the error message still appears.

  • Note1: I am able to register payment if I use admin user.
  • Note2: Not sure if it could be releated with having multicompany enabled.

EDIT1:
Checking Odoo server logs I found this:

bad query: INSERT INTO "account_full_reconcile" ("id", "name", "create_uid", "write_uid", "create_date", "write_date") VALUES(nextval('account_full_reconcile_id_seq'), NULL, 7, 7, (now() at time zone 'UTC'), (now() at time zone 'UTC')) RETURNING id

EDIT2:
In the previous bad query error can be seen that problem is that "name" field is Null.Label for this field is "Number".

So checking "account_full_reconcile" table in Odoo database, in the column "name" I have two non-consecutive values: "A1" and "A4". Also in column "id" there are non-consecutive id: "19" and "30". Not sure if It's related with the error.

2
This question was originally asked by other user in odoo.com/es_ES/forum/ayuda-1/question/….Pin
With multi company enabled, it could be that all accounting features like periods, journals, etc. are not configured correctly. Did you check that? Is there a journal for your active company?CZoellner
Yes, I checked it and seems ok to me: Under Accounting > Configuration > Accounting there are Journals, Taxes, Fiscal Positions and Bank Accounts for my active company. Note "Spain - Accounting (PGCE 2008)" app is installed.Pin
What about payment terms? Do you use them? It seems that payment terms are multi-company ready, too, but you can't see the company on them. Try to find out, if there is a problem. (had the same issue on a customer of us)CZoellner
I don't use payment terms, but using it nothing change and I still get same error. Maybe error is related with what I tell in the question edit 2.Pin

2 Answers

3
votes

I think I found out...I had to manually create an "account Reconcile Sequence" record for the 2nd company...just duplicated and cahnge Company. From Technical -- sequences -- Account reconcile sequence.

4
votes

In odoo 9 the screen at "From Technical -- sequences -- Account reconcile sequence" doesn't have option to set company, so odoo9 users can do just duplicate it and create a new record and from backend in the database update that new record company_id value with your compant id