-
Notifications
You must be signed in to change notification settings - Fork 152
Open
Description
Error
SQL query:
CREATE TABLE orders (
id int(11) unsigned NOT NULL AUTO_INCREMENT,
Title varchar(255) DEFAULT NULL,
First varchar(255) DEFAULT NULL,
Middle varchar(255) DEFAULT NULL,
Last varchar(255) DEFAULT NULL,
ProductId int(11) unsigned NOT NULL,
NumberShipped int(11) DEFAULT NULL,
OrderDate date DEFAULT NULL,
PRIMARY KEY (id),
KEY order_product_fk (ProductId),
CONSTRAINT order_product_fk FOREIGN KEY (ProductId) REFERENCES products (id)
) ENGINE=InnoDB DEFAULT CHARSET=utf8
MySQL said: Documentation
#1005 - Can't create table inventorymanager_2017-06-22.orders (errno: 150 "Foreign key constraint is incorrectly formed") (Details…)
Metadata
Metadata
Assignees
Labels
No labels