BAD DB設計に対するSQLパターン入門

CREATE TABLE  `fruit` (
`fruit_id` INT NOT NULL AUTO_INCREMENT PRIMARY KEY ,
`fruit_name` VARCHAR( 255 ) NOT NULL
) ENGINE = INNODB;
INSERT INTO fruit (fruit_id,fruit_name) VALUES 
(1,'いちご'),
(2,'レモン'),
(3,'メロン'),
(4,'キューイ'),
(5,'オレンジ'),
(6,'ブルーベリー');
CREATE TABLE  `basket` (
`bascket_id` INT NOT NULL AUTO_INCREMENT PRIMARY KEY ,
`fruit1` INT NULL ,
`fruit2` INT NULL ,
`fruit3` INT NULL ,
`fruit4` INT NULL ,
`fruit5` INT NULL
) ENGINE = INNODB COMMENT =  'バスケット';
CREATE TABLE `fruit_bascket` (
`fruit_bascket_id` INT NOT NULL AUTO_INCREMENT PRIMARY KEY ,
`bascket_id` INT NOT NULL ,
`fruit_id` INT NOT NULL
) ENGINE = INNODB;