mysql
create table trkr_admin(
id tinyint unsigned not null auto_increment primary key comment "ID",
name CHAR(30) not null default "" comment "",
cname CHAR(30) not null default "" comment "",
password char(32) not null default "" comment "",
status tinyint not null default "1" comment " 1 2",
UNIQUE(name),
UNIQUE(cname),
index(name)
)engine=InnoDB charset=utf8mb4;
create table trkr_article(
id int unsigned not null auto_increment primary key comment "ID",
title char(20) not null default "" comment "",
content varchar(16000) not null default " " comment "",
bind_adminname_id tinyint unsigned not null comment "",
FOREIGN KEY(bind_adminname_id) REFERENCES trkr_admin(id),
FULLTEXT (title,content) WITH PARSER ngram
)engine=InnoDB charset=utf8mb4;
error message : ERROR 1215 (HY000): Cannot add foreign key constraint
)