Add foreign key to products

This commit is contained in:
Jay Trees 2022-01-17 14:17:29 +01:00
parent c3dc1221f7
commit 24f592f954

View file

@ -119,7 +119,10 @@ switch ($step) {
$database->query('CREATE TABLE `products` ( $database->query('CREATE TABLE `products` (
`id` int NOT NULL PRIMARY KEY AUTO_INCREMENT, `id` int NOT NULL PRIMARY KEY AUTO_INCREMENT,
`wishlist` int NOT NULL, `wishlist` int NOT NULL,
`url` VARCHAR(255) NOT NULL, `url` VARCHAR(255) NOT NULL
FOREIGN KEY (`wishlist`)
REFERENCES `wishlists` (id)
ON DELETE CASCADE
);'); );');
/** /**