Bỏ qua để đến Nội dung
Menu
Câu hỏi này đã bị gắn cờ
1 Trả lời
3446 Lượt xem

I've deleted this constraint  stock_quant_product_id_fkey  but still showing this error.

Error:

The operation cannot be completed: another model requires the record being deleted. If possible, archive it instead. Model: Quants (stock.quant), Constraint: stock_quant_product_id_fkey

Logs: 

psycopg2.IntegrityError: insert or update on table "stock_quant" violates foreign key constraint "stock_quant_product_id_fkey"

DETAIL: Key (product_id)=(40057) is not present in table "product_product".



Ảnh đại diện
Huỷ bỏ
Câu trả lời hay nhất

You are trying to insert a product id in product_id field which isn't exist on product_product table

Ảnh đại diện
Huỷ bỏ
Bài viết liên quan Trả lời Lượt xem Hoạt động
1
thg 3 23
2090
1
thg 10 23
1226
2
thg 3 23
2893
3
thg 8 22
8887
1
thg 10 21
11365