1
DROP TABLE IF EXISTS `a`;
2
DROP TABLE IF EXISTS `aa`;
3
DROP TABLE IF EXISTS `c`;
5
`pk` INT NOT NULL DEFAULT '0',
6
`col_enum_key` ENUM('a','b','c','d','e','f','g','h','i','j','k','l','m','n','o','p','q','r','s','t','u','v','w','x','y','z') DEFAULT NULL,
8
KEY `col_enum_key` (`col_enum_key`)
9
) ENGINE=InnoDB COLLATE = utf8_general_ci;
11
`pk` INT NOT NULL DEFAULT '0',
12
`col_int_not_null_key` INT NOT NULL,
14
KEY `col_int_not_null_key` (`col_int_not_null_key`)
15
) ENGINE=InnoDB COLLATE = utf8_general_ci;
16
INSERT INTO `aa` VALUES (1,-523436032),(2,1),(3,621543424),(4,880148480),(5,1963982848),(6,8),(7,1445462016),(8,0),(9,-747241472),(10,6);
18
`pk` INT NOT NULL DEFAULT '0',
19
`col_int_key` INT DEFAULT NULL,
20
`col_enum_key` ENUM('a','b','c','d','e','f','g','h','i','j','k','l','m','n','o','p','q','r','s','t','u','v','w','x','y','z') DEFAULT NULL,
22
KEY `col_int_key` (`col_int_key`),
23
KEY `col_enum_key` (`col_enum_key`)
24
) ENGINE=InnoDB COLLATE = utf8_general_ci;
25
INSERT INTO `c` VALUES (1,NULL,'h');
26
SELECT X . `col_int_key` FROM `c` AS X LEFT JOIN `a` AS Y USING ( `col_enum_key` ) WHERE X . `col_enum_key` = ( SELECT `col_int_not_null_key` FROM `aa` WHERE `pk` = 5 ) LIMIT 8 ;
27
ERROR HY000: Received an invalid enum value '1963982848'.
28
DROP TABLE `a`,`aa`,`c`;