Skip to Content
Odoo Meniu
  • Autentificare
  • Try it free
  • Aplicații
    Finanțe
    • Contabilitate
    • Facturare
    • Cheltuieli
    • Spreadsheet (BI)
    • Documente
    • Semn
    Vânzări
    • CRM
    • Vânzări
    • POS Shop
    • POS Restaurant
    • Abonamente
    • Închiriere
    Site-uri web
    • Constructor de site-uri
    • eCommerce
    • Blog
    • Forum
    • Live Chat
    • eLearning
    Lanț Aprovizionare
    • Inventar
    • Producție
    • PLM
    • Achiziție
    • Maintenance
    • Calitate
    Resurse Umane
    • Angajați
    • Recrutare
    • Time Off
    • Evaluări
    • Referințe
    • Flotă
    Marketing
    • Social Marketing
    • Marketing prin email
    • SMS Marketing
    • Evenimente
    • Automatizare marketing
    • Sondaje
    Servicii
    • Proiect
    • Foi de pontaj
    • Servicii de teren
    • Centru de asistență
    • Planificare
    • Programări
    Productivitate
    • Discuss
    • Aprobări
    • IoT
    • VoIP
    • Knowledge
    • WhatsApp
    Aplicații Terțe Odoo Studio Platforma Odoo Cloud
  • Industrii
    Retail
    • Book Store
    • Magazin de îmbrăcăminte
    • Magazin de Mobilă
    • Magazin alimentar
    • Magazin de materiale de construcții
    • Magazin de jucării
    Food & Hospitality
    • Bar and Pub
    • Restaurant
    • Fast Food
    • Guest House
    • Distribuitor de băuturi
    • Hotel
    Proprietate imobiliara
    • Real Estate Agency
    • Firmă de Arhitectură
    • Construcție
    • Estate Managament
    • Grădinărit
    • Asociația Proprietarilor de Proprietăți
    Consultanta
    • Firma de Contabilitate
    • Partener Odoo
    • Agenție de marketing
    • Law firm
    • Atragere de talente
    • Audit & Certification
    Producție
    • Textil
    • Metal
    • Mobilier
    • Mâncare
    • Brewery
    • Cadouri corporate
    Health & Fitness
    • Club Sportiv
    • Magazin de ochelari
    • Centru de Fitness
    • Wellness Practitioners
    • Farmacie
    • Salon de coafură
    Trades
    • Handyman
    • IT Hardware and Support
    • Asigurare socială de stat
    • Cizmar
    • Servicii de curățenie
    • HVAC Services
    Altele
    • Organizație nonprofit
    • Agenție de Mediu
    • Închiriere panouri publicitare
    • Fotografie
    • Închiriere biciclete
    • Asigurare socială
    Browse all Industries
  • Comunitate
    Învăță
    • Tutorials
    • Documentație
    • Certificări
    • Instruire
    • Blog
    • Podcast
    Empower Education
    • Program Educațional
    • Scale Up! Business Game
    • Visit Odoo
    Obține Software-ul
    • Descărcare
    • Compară Edițiile
    • Lansări
    Colaborați
    • Github
    • Forum
    • Evenimente
    • Translations
    • Devino Partener
    • Services for Partners
    • Înregistrează-ți Firma de Contabilitate
    Obține Servicii
    • Găsește un Partener
    • Găsiți un contabil
    • Meet an advisor
    • Servicii de Implementare
    • Referințe ale clienților
    • Suport
    • Actualizări
    Github Youtube Twitter Linkedin Instagram Facebook Spotify
    +1 (650) 691-3277
    Obține un demo
  • Prețuri
  • Ajutor

Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:

  • CRM
  • e-Commerce
  • Contabilitate
  • Inventar
  • PoS
  • Proiect
  • MRP
All apps
Trebuie să fiți înregistrat pentru a interacționa cu comunitatea.
All Posts Oameni Insigne
Etichete (View all)
odoo accounting v14 pos v15
Despre acest forum
Trebuie să fiți înregistrat pentru a interacționa cu comunitatea.
All Posts Oameni Insigne
Etichete (View all)
odoo accounting v14 pos v15
Despre acest forum
Suport

Problem installing Inventory management module

Abonare

Primiți o notificare când există activitate la acestă postare

Această întrebare a fost marcată
6 Răspunsuri
6947 Vizualizări
Imagine profil
Gilles

Hi,

I'm trying to install inventory module on odoo 9 but there is an error when I clic on install:

Odoo Warning - Validation ErrorThe 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: stock_picking - stock.picking]

Then I can just clic on Cancel install.

Here is part of postgres serveur log file:

2016-11-14 23:11:48 CET [31598-1] odoo@odoo2 ERROR: column "name" contains null values2016-11-14 23:11:48 CET [31598-2] odoo@odoo2 STATEMENT: ALTER TABLE "stock_location" ALTER COLUMN "name" SET NOT NULL2016-11-14 23:11:48 CET [31598-3] odoo@odoo2 ERROR: column "name" contains null values2016-11-14 23:11:48 CET [31598-4] odoo@odoo2 STATEMENT: ALTER TABLE "stock_location_route" ALTER COLUMN "name" SET NOT NULL2016-11-14 23:11:49 CET [31598-5] odoo@odoo2 ERROR: column "product_uom" contains null values2016-11-14 23:11:49 CET [31598-6] odoo@odoo2 STATEMENT: ALTER TABLE "stock_move" ALTER COLUMN "product_uom" SET NOT NULL2016-11-14 23:11:49 CET [31598-7] odoo@odoo2 ERROR: column "location_id" contains null values2016-11-14 23:11:49 CET [31598-8] odoo@odoo2 STATEMENT: ALTER TABLE "stock_move" ALTER COLUMN "location_id" SET NOT NULL2016-11-14 23:11:49 CET [31598-9] odoo@odoo2 ERROR: column "name" contains null values2016-11-14 23:11:49 CET [31598-10] odoo@odoo2 STATEMENT: ALTER TABLE "stock_move" ALTER COLUMN "name" SET NOT NULL2016-11-14 23:11:49 CET [31598-11] odoo@odoo2 ERROR: column "location_dest_id" contains null values2016-11-14 23:11:49 CET [31598-12] odoo@odoo2 STATEMENT: ALTER TABLE "stock_move" ALTER COLUMN "location_dest_id" SET NOT NULL2016-11-14 23:11:49 CET [31598-13] odoo@odoo2 ERROR: column "product_id" contains null values2016-11-14 23:11:49 CET [31598-14] odoo@odoo2 STATEMENT: ALTER TABLE "stock_move" ALTER COLUMN "product_id" SET NOT NULL2016-11-14 23:11:49 CET [31598-15] odoo@odoo2 ERROR: column "location_id" contains null values2016-11-14 23:11:49 CET [31598-16] odoo@odoo2 STATEMENT: ALTER TABLE "stock_pack_operation" ALTER COLUMN "location_id" SET NOT NULL2016-11-14 23:11:49 CET [31598-17] odoo@odoo2 ERROR: column "location_dest_id" contains null values2016-11-14 23:11:49 CET [31598-18] odoo@odoo2 STATEMENT: ALTER TABLE "stock_pack_operation" ALTER COLUMN "location_dest_id" SET NOT NULL2016-11-14 23:11:50 CET [31598-19] odoo@odoo2 ERROR: insert or update on table "stock_move" violates foreign key constraint "stock_move_picking_id_fkey"2016-11-14 23:11:50 CET [31598-20] odoo@odoo2 DETAIL: Key (picking_id)=(3) is not present in table "stock_picking". 2016-11-14 23:11:50 CET [31598-21] odoo@odoo2 STATEMENT: ALTER TABLE "stock_move" ADD FOREIGN KEY ("picking_id") REFERENCES "stock_picking" ON DELETE set null

Here is odoo log file for this:

2016-11-14 22:11:48,501 22714 INFO odoo2 openerp.modules.loading: loading 1 modules... 2016-11-14 22:11:48,511 22714 INFO odoo2 openerp.modules.loading: 1 modules loaded in 0.01s, 0 queries2016-11-14 22:11:48,574 22714 INFO odoo2 openerp.modules.loading: loading 46 modules... 2016-11-14 22:11:48,614 22714 INFO odoo2 openerp.modules.loading: 46 modules loaded in 0.04s, 0 queries2016-11-14 22:11:48,619 22714 ERROR odoo2 openerp.modules.graph: module sale_mrp: Unmet dependencies: mrp2016-11-14 22:11:48,619 22714 WARNING odoo2 openerp.modules.graph: Some modules were not loaded. 2016-11-14 22:11:48,620 22714 INFO odoo2 openerp.modules.loading: loading 51 modules... 2016-11-14 22:11:48,791 22714 INFO odoo2 openerp.modules.module: module stock: creating or updating database tables2016-11-14 22:11:48,860 22714 WARNING odoo2 openerp.models.schema: Table 'stock_location': unable to set a NOT NULL constraint on column 'name' ! If you want to have it, you should update the records and execute manually: ALTER TABLE stock_location ALTER COLUMN name SET NOT NULL2016-11-14 22:11:48,896 22714 WARNING odoo2 openerp.models.schema: Table 'stock_location_route': unable to set a NOT NULL constraint on column 'name' ! If you want to have it, you should update the records and execute manually: ALTER TABLE stock_location_route ALTER COLUMN name SET NOT NULL2016-11-14 22:11:49,024 22714 WARNING odoo2 openerp.models.schema: Table 'stock_move': unable to set a NOT NULL constraint on column 'product_uom' ! If you want to have it, you should update the records and execute manually: ALTER TABLE stock_move ALTER COLUMN product_uom SET NOT NULL2016-11-14 22:11:49,037 22714 WARNING odoo2 openerp.models.schema: Table 'stock_move': unable to set a NOT NULL constraint on column 'location_id' ! If you want to have it, you should update the records and execute manually: ALTER TABLE stock_move ALTER COLUMN location_id SET NOT NULL2016-11-14 22:11:49,074 22714 WARNING odoo2 openerp.models.schema: Table 'stock_move': unable to set a NOT NULL constraint on column 'name' ! If you want to have it, you should update the records and execute manually: ALTER TABLE stock_move ALTER COLUMN name SET NOT NULL2016-11-14 22:11:49,080 22714 WARNING odoo2 openerp.models.schema: Table 'stock_move': unable to set a NOT NULL constraint on column 'location_dest_id' ! If you want to have it, you should update the records and execute manually: ALTER TABLE stock_move ALTER COLUMN location_dest_id SET NOT NULL2016-11-14 22:11:49,085 22714 WARNING odoo2 openerp.models.schema: Table 'stock_move': unable to set a NOT NULL constraint on column 'product_id' ! If you want to have it, you should update the records and execute manually: ALTER TABLE stock_move ALTER COLUMN product_id SET NOT NULL2016-11-14 22:11:49,310 22714 WARNING odoo2 openerp.models.schema: Table 'stock_pack_operation': unable to set a NOT NULL constraint on column 'location_id' ! If you want to have it, you should update the records and execute manually: ALTER TABLE stock_pack_operation ALTER COLUMN location_id SET NOT NULL2016-11-14 22:11:49,322 22714 WARNING odoo2 openerp.models.schema: Table 'stock_pack_operation': unable to set a NOT NULL constraint on column 'location_dest_id' ! If you want to have it, you should update the records and execute manually: ALTER TABLE stock_pack_operation ALTER COLUMN location_dest_id SET NOT NULL2016-11-14 22:11:50,149 22714 INFO odoo2 openerp.sql_db: bad query: ALTER TABLE "stock_move" ADD FOREIGN KEY ("picking_id") REFERENCES "stock_picking" ON DELETE set null

2016-11-14 22:11:50,150 22714 ERROR odoo2 openerp.modules.registry: Failed to load registryTraceback (most recent call last): File "/usr/lib/python2.7/dist-packages/openerp/modules/registry.py", line 386, in new openerp.modules.load_modules(registry._db, force_demo, status, update_module) File "/usr/lib/python2.7/dist-packages/openerp/modules/loading.py", line 338, in load_modules loaded_modules, update_module) File "/usr/lib/python2.7/dist-packages/openerp/modules/loading.py", line 237, in load_marked_modules loaded, processed = load_module_graph(cr, graph, progressdict, report=report, skip_modules=loaded_modules, perform_checks=perform_checks) File "/usr/lib/python2.7/dist-packages/openerp/modules/loading.py", line 137, in load_module_graph init_module_models(cr, package.name, models) File "/usr/lib/python2.7/dist-packages/openerp/modules/module.py", line 307, in init_module_models obj._auto_end(cr, {'module': module_name}) File "/usr/lib/python2.7/dist-packages/openerp/api.py", line 250, in wrapper return old_api(self, *args, **kwargs) File "/usr/lib/python2.7/dist-packages/openerp/models.py", line 2716, in _auto_end cr.execute('ALTER TABLE "%s" ADD FOREIGN KEY ("%s") REFERENCES "%s" ON DELETE %s' % (t, k, r, d)) File "/usr/lib/python2.7/dist-packages/openerp/sql_db.py", line 141, in wrapper return f(self, *args, **kwargs) File "/usr/lib/python2.7/dist-packages/openerp/sql_db.py", line 220, in execute res = self._obj.execute(query, params)IntegrityError: insert or update on table "stock_move" violates foreign key constraint "stock_move_picking_id_fkey"DETAIL: Key (picking_id)=(3) is not present in table "stock_picking". 2016-11-14 22:11:50,155 22714 INFO odoo2 openerp.modules.loading: loading 1 modules... 2016-11-14 22:11:50,167 22714 INFO odoo2 openerp.modules.loading: 1 modules loaded in 0.01s, 0 queries2016-11-14 22:11:50,194 22714 INFO odoo2 openerp.modules.loading: loading 46 modules... 2016-11-14 22:11:50,238 22714 INFO odoo2 openerp.modules.loading: 46 modules loaded in 0.04s, 0 queries2016-11-14 22:11:50,736 22714 INFO odoo2 openerp.modules.loading: Modules loaded.

I've already tried to duplicate database: same issue

I try to create new database and I can install inventory module on it but I need to install module on first database that contains datas.

What can I do ? Thanks for help.

0
Imagine profil
Abandonează
Ermin Trevisan

Hi, thanks for answering.

This is fresh install, we start from odoo 9, maybe some modules were installed incorrectly. I've checked differences between both databases and I can see that some tables are missing on database that contains datas.

We have executed manually all of (correct) ALTER TABLE indicated into the log file and now the persistent error stays:

2016-11-15 15:38:18 CET [31598-42] odoo@odoo2 ERROR: insert or update on table "stock_move" violates foreign key constraint "stock_move_location_dest_id_fkey"2016-11-15 15:38:18 CET [31598-43] odoo@odoo2 DETAIL: Key (location_dest_id)=(0) is not present in table "stock_location". 2016-11-15 15:38:18 CET [31598-44] odoo@odoo2 STATEMENT: ALTER TABLE "stock_move" ADD FOREIGN KEY ("location_dest_id") REFERENCES "stock_location" ON DELETE set null

Is there a way to reinstall odoo without loosing datas ? I'd like to avoid to reinstall everything and begin from scratch again ...

Thanks

Ermin Trevisan

Do make a backup before you install modules, especially if you are not sure about the quality and compatibility of such modules. You should definitely go for a clean install with loosing your data.

Imagine profil
ralfeus@gmail.com
Cel mai bun răspuns

I had same problem. In my case it stated:

2019-01-10 08:12:25,649 1528 ERROR odoo odoo.sql_db: bad query: b'ALTER TABLE "stock_picking" ADD FOREIGN KEY ("location_id") REFERENCES "stock_location"("id") ON DELETE set null'
ERROR: insert or update on table "stock_picking" violates foreign key constraint "stock_picking_location_id_fkey"
DETAIL:  Key (location_id)=(12) is not present in table "stock_location".

I noticed there was no table "stock_location" at all as well as any other table starting with "stock_". Only table I saw was "stock_picking". So I removed this table assuming it would be created during installation of the module. And that's exactly what's happened. The table "stock_picking" as well as other "stock_*" ones were created and Inventory module was installed successfully.

So I'd recommend to remove all "stock_*" tables from the database and try to install Inventory module again

0
Imagine profil
Abandonează
Imagine profil
Gilles
Autor Cel mai bun răspuns

Hi Patrick,

We didn't find any solution, we had to create a new database and configure again. To avoid new problem, I made a backup before each module installation to be able to rollback if needed. Sorry ...

0
Imagine profil
Abandonează
Imagine profil
Patrick Miller
Cel mai bun răspuns

Hi Giles, did you ever find a solution? I'm having the same issue. Thanks.

0
Imagine profil
Abandonează
Imagine profil
el mehdi
Cel mai bun răspuns

Hello Gilles,

maybe the error came from an other module you did try to install before but you did not cancell installation, and is not compatible with the version of odoo you are using.


0
Imagine profil
Abandonează
Enjoying the discussion? Don't just read, join in!

Create an account today to enjoy exclusive features and engage with our awesome community!

Înscrie-te
Comunitate
  • Tutorials
  • Documentație
  • Forum
Open Source
  • Descărcare
  • Github
  • Runbot
  • Translations
Servicii
  • Hosting Odoo.sh
  • Suport
  • Actualizare
  • Custom Developments
  • Educație
  • Găsiți un contabil
  • Găsește un Partener
  • Devino Partener
Despre Noi
  • Compania noastră
  • Active de marcă
  • Contactați-ne
  • Locuri de muncă
  • Evenimente
  • Podcast
  • Blog
  • Clienți
  • Aspecte juridice • Confidențialitate
  • Securitate
الْعَرَبيّة Català 简体中文 繁體中文 (台灣) Čeština Dansk Nederlands English Suomi Français Deutsch हिंदी Bahasa Indonesia Italiano 日本語 한국어 (KR) Lietuvių kalba Język polski Português (BR) română русский язык Slovenský jazyk slovenščina Español (América Latina) Español ภาษาไทย Türkçe українська Tiếng Việt

Odoo este o suită de aplicații de afaceri open source care acoperă toate nevoile companiei dvs.: CRM, comerț electronic, contabilitate, inventar, punct de vânzare, management de proiect etc.

Propunerea de valoare unică a Odoo este să fie în același timp foarte ușor de utilizat și complet integrat.

Website made with

Odoo Experience on YouTube

1. Use the live chat to ask your questions.
2. The operator answers within a few minutes.

Live support on Youtube
Watch now