【发布时间】:2016-05-08 00:04:15
【问题描述】:
CREATE TABLE IF Not EXISTS `conversation` (
`c_id` int(11) NOT NULL PRIMARY KEY AUTO_INCREMENT,
`user_one` int(11) NOT NULL,
`user_two` int(11) NOT NULL,
`ip` varchar(30) DEFAULT NULL,
`time` int(11) DEFAULT NULL,
FOREIGN KEY (user_one) REFERENCES users(user_id),
FOREIGN KEY (user_two) REFERENCES users(user_id)
);
这是我的 SQL 查询。我收到此错误
1215 - Impossible d'ajouter des contraintes d'index externe
【问题讨论】:
-
你能帮我创建这个表吗,因为你提供的链接已经给出了添加 UNSIGNED 的解决方案,但这不起作用
标签: mysql