这个MySQL创建表的语句哪里错了,为什么总是报错
CREATETABLEexample4(idINTNOTNULL,PRIMARYKEY,nameVARCHAR(20)NOTNULL,stu_idINT,CONSTRAI...
CREATE TABLE example4(
id INT NOT NULL,PRIMARY KEY,
name VARCHAR(20) NOT NULL,
stu_id INT,
CONSTRAINT d_fk FOREIGN KEY(stu_id) REFERENCES example1(stu_id)
); 展开
id INT NOT NULL,PRIMARY KEY,
name VARCHAR(20) NOT NULL,
stu_id INT,
CONSTRAINT d_fk FOREIGN KEY(stu_id) REFERENCES example1(stu_id)
); 展开
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询