| Bug #10541 | Load DATA not support to 'ENUM' And 'SET' data type | ||
|---|---|---|---|
| Submitted: | 11 May 2005 11:21 | Modified: | 12 May 2005 21:24 |
| Reporter: | Disha | Email Updates: | |
| Status: | Not a Bug | Impact on me: | |
| Category: | MySQL Server | Severity: | S2 (Serious) |
| Version: | 5.0.5-beta-nt | OS: | Windows (Windows xp) |
| Assigned to: | MySQL Verification Team | CPU Architecture: | Any |
[11 May 2005 17:36]
MySQL Verification Team
The behavior reported only happens on Windows server, on
Linux server it works:
mysql> LOAD DATA INFILE '/home/miguel/f/t1.txt' INTO TABLE t1//
Query OK, 3 rows affected (0.01 sec)
Records: 3 Deleted: 0 Skipped: 0 Warnings: 0
mysql> select * from t1;
-> //
+----+
| s1 |
+----+
| a |
| b |
| c |
+----+
3 rows in set (0.00 sec)
[12 May 2005 21:24]
MySQL Verification Team
mysql> LOAD DATA INFILE 'c:\\t1.txt' INTO TABLE t1 LINES TERMINATED BY "\r\n"// Query OK, 3 rows affected (0.01 sec) Records: 3 Deleted: 0 Skipped: 0 Warnings: 0 mysql> select * from t1// +----+ | s1 | +----+ | a | | b | | c | +----+ 3 rows in set (0.01 sec) mysql> select version()// +---------------+ | version() | +---------------+ | 5.0.6-beta-nt | +---------------+ 1 row in set (0.03 sec)

Description: If I try to insert data into table using 'LOAD DATA' it is not inseting value in column of data type 'ENUM' and 'SET' A) Values for file t1.txt a b c How to repeat: A. execute the following command. 1.delimiter // 2.set @@sql_mode='STRICT_ALL_TABLES'// 3.drop table if exists t1// 4.create table t1 (s1 enum('a','b','c') not null default 'a')// 5.LOAD DATA INFILE 'c:\\t1.txt' INTO TABLE t1// B. Expected Result: Sucessful data insert with warning with setting default value for column C) Actual Result: ERROR 1265 (01000): Data truncated for column 's1' at row 1