1. 외래키 테이블 락 걸기 lock table 참조테이블명 write, 내테이블명 write; //foreign key가 걸려있는 내테이블과 참조테이블에 lock lock table course write, attend write; 2. 외래키 지우기 alter table 내테이블명 drop foreign key 내테이블명_ibfk_2; //내테이블에서 참조데이블을 끊기! alter table attend drop foreign key attend_ibfk_2; 3. 속성 넣기 alter table course modify co_num int not null auto_increment; //참조테이블의 속성 설정 다시하기 alter table 참조테이블명 modify 칼럼명 int not null au..