Add foreign key to users
This commit is contained in:
parent
453106c277
commit
7441716bc4
1 changed files with 4 additions and 1 deletions
|
@ -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
|
||||
);');
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in a new issue