java-tutorials/flyway-migration/db/migration/V2_0__create_department_sch...

8 lines
210 B
MySQL
Raw Normal View History

CREATE TABLE IF NOT EXISTS `department` (
`id` int NOT NULL AUTO_INCREMENT PRIMARY KEY,
`name` varchar(20)
)ENGINE=InnoDB DEFAULT CHARSET=UTF8;
ALTER TABLE `employee` ADD `dept_id` int AFTER `email`;