Add foreign key to users

This commit is contained in:
Jay Trees 2022-01-17 14:30:41 +01:00
parent 453106c277
commit 7441716bc4

View file

@ -110,7 +110,10 @@ switch ($step) {
$database->query('CREATE TABLE `wishlists` (
`id` int PRIMARY KEY AUTO_INCREMENT,
`user` int NOT NULL,
`name` varchar(128) NOT NULL
`name` varchar(128) NOT NULL,
FOREIGN KEY (`user`)
REFERENCES `users` (`id`)
ON DELETE CASCADE
);');
/**