SQL Error [1075] [42000]: (conn=11) Incorrect table definition; there can be only one auto column and it must be defined as a key
create table TB_BOARD (
BOARD_MASTER_ID INT not null COMMENT '게시판ID'
, BOARD_ID INT not null auto_increment COMMENT '게시글ID'
, TITLE VARCHAR(200) not null COMMENT '제목'
, CONTENTS TEXT not null COMMENT '내용'
, PRIMARY KEY (BOARD_MASTER_ID, BOARD_ID)
) ENGINE=InnoDB DEFAULT CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI;
create table TB_BOARD (
BOARD_MASTER_ID INT not null COMMENT '게시판ID'
, BOARD_ID INT not null auto_increment COMMENT '게시글ID'
, TITLE VARCHAR(200) not null COMMENT '제목'
, CONTENTS TEXT not null COMMENT '내용'
, PRIMARY KEY (BOARD_ID, BOARD_MASTER_ID)
) ENGINE=InnoDB DEFAULT CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI;
Incorrect table definition; there can be only one auto column and it must be defined as a key, but it is
I'm having this error when I try to create the table "subcategorias" in MySQL ERROR 1075 (42000): Incorrect table definition; there can be only one auto column and it must be defined as a key ...
stackoverflow.com
댓글 영역