added sql to current sql

This commit is contained in:
Fredrik Friis 2012-04-13 19:16:00 +09:00
parent 29d25873a8
commit 335125dc32

@ -0,0 +1,12 @@
CREATE TABLE IF NOT EXISTS `CheckList_userLastOpenDate` (
`CheckList_id` bigint(20) NOT NULL,
`userLastOpenDate` datetime DEFAULT NULL,
`userLastOpenDate_KEY` bigint(20) NOT NULL,
PRIMARY KEY (`CheckList_id`,`userLastOpenDate_KEY`),
KEY `FKF7E07AB26D025A9` (`userLastOpenDate_KEY`),
KEY `FKF7E07AB21F327355` (`CheckList_id`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1;
ALTER TABLE `CheckList_userLastOpenDate`
ADD CONSTRAINT `FKF7E07AB21F327355` FOREIGN KEY (`CheckList_id`) REFERENCES `checklist` (`id`),
ADD CONSTRAINT `FKF7E07AB26D025A9` FOREIGN KEY (`userLastOpenDate_KEY`) REFERENCES `user` (`id`);