Bug #14523 CSV table: select gives wrong answer
Submitted: 31 Oct 2005 21:07 Modified: 19 Nov 2005 1:19
Reporter: Peter Gulutzan Email Updates:
Status: Duplicate Impact on me:
None 
Category:MySQL Server Severity:S3 (Non-critical)
Version:5.1.2-alpha-debug OS:Linux (SUSE 10.0)
Assigned to: Bugs System CPU Architecture:Any

[31 Oct 2005 21:07] Peter Gulutzan
Description:
After a few inserts and updates, a select from a CSV table
yields the wrong answer.
The same statement sequence works fine with MySQL 5.0.

How to repeat:
mysql> create table csv (s1 int) engine=csv;
Query OK, 0 rows affected (0.00 sec)

mysql> insert into csv values (0);
Query OK, 1 row affected (0.00 sec)

mysql> update csv set s1 = s1 + 1;
Query OK, 1 row affected (0.00 sec)
Rows matched: 1  Changed: 1  Warnings: 0

mysql> select * from csv;
+------+
| s1   |
+------+
|    1 |
+------+
1 row in set (0.00 sec)

mysql> insert into csv select s1 from csv;
Query OK, 1 row affected (0.00 sec)
Records: 1  Duplicates: 0  Warnings: 0

mysql> select * from csv;
+------+
| s1   |
+------+
|    1 |
|    0 |
+------+
2 rows in set (0.00 sec)
[19 Nov 2005 1:19] Patrick Galbraith
duplicate of Bug #13406