[MDEV-12573] Accept=1 may show incorrect value for NULL column in CONNECT TBL Created: 2017-04-24  Updated: 2017-05-11  Resolved: 2017-05-11

Status: Closed
Project: MariaDB Server
Component/s: Storage Engine - Connect
Affects Version/s: 10.1.22
Fix Version/s: 10.1.24, 10.0.31, 10.2.6, 10.3.1

Type: Bug Priority: Major
Reporter: Alice Sherepa Assignee: Olivier Bertrand
Resolution: Fixed Votes: 0
Labels: None


 Description   

Column 'm' should have null in last 3 rows

CREATE TABLE q (
  id INT NOT NULL
) ENGINE=CONNECT TABLE_TYPE=CSV;
Query OK, 0 rows affected, 1 warning (0.02 sec)
Warning (Code 1105): No file name. Table will use q.csv
 
INSERT INTO q VALUES(1),(2),(3);
Query OK, 3 rows affected (0.00 sec)
Records: 3  Duplicates: 0  Warnings: 0
 
CREATE TABLE w (
  id INT NOT NULL, 
  m char (10)
) ENGINE=Innodb;
Query OK, 0 rows affected (0.12 sec)
 
INSERT INTO w VALUES(1,'a'),(2,'b'),(3,'c');
Query OK, 3 rows affected (0.01 sec)
Records: 3  Duplicates: 0  Warnings: 0
 
create table rt1(
id int not null,
m char(10)
)engine=connect  table_type= TBL table_list='q,w,q', option_list='Accept=1';
Query OK, 0 rows affected (0.02 sec)
 
select * from rt1;
+----+------+
| id | m    |
+----+------+
|  1 |      |
|  2 |      |
|  3 |      |
|  1 | a    |
|  2 | b    |
|  3 | c    |
|  1 | c    |
|  2 | c    |
|  3 | c    |
+----+------+
9 rows in set (0.00 sec)


Generated at Thu Feb 08 07:58:45 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.