Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-12688

INSERT INTO tinyint of CONNECT.JSON brings NULL

    Details

      Description

      After inserting values into a column, that is defined as TINYINT (JSON table, CONNECT engine), result values are NULL

      --------------
      create table t1(
      	 i1 int,
              i2 int,
              i3 int
      )engine=CONNECT table_type=JSON  File_name='/home/alice/Downloads/3.json'
      --------------
      Query OK, 0 rows affected (0.07 sec)
       
      --------------
      insert into t1 values(1,1,1)
      --------------
      Query OK, 1 row affected (0.00 sec)
       
      --------------
      select * from t1
      --------------
      +------+------+------+
      | i1   | i2   | i3   |
      +------+------+------+
      |    1 |    1 |    1 |
      +------+------+------+
      1 row in set (0.00 sec)
       
      --------------
      create table t2(
      	    i1 tinyint,
              i2 tinyint,
              i3 tinyint
      )engine=CONNECT table_type=JSON  File_name='/home/alice/Downloads/3.json'
      --------------
      Query OK, 0 rows affected (0.06 sec)
       
      --------------
      select * from t2
      --------------
      +------+------+------+
      | i1   | i2   | i3   |
      +------+------+------+
      |    1 |    1 |    1 |
      +------+------+------+
      1 row in set (0.00 sec)
       
      --------------
      insert into t2 values(1,1,1)
      --------------
      Query OK, 1 row affected (0.00 sec)
       
      --------------
      select * from t2
      --------------
      +------+------+------+
      | i1   | i2   | i3   |
      +------+------+------+
      |    1 |    1 |    1 |
      | NULL | NULL | NULL |
      +------+------+------+
      2 rows in set (0.00 sec)
      

        Attachments

          Activity

            People

            • Assignee:
              bertrandop Olivier Bertrand
              Reporter:
              alice Alice Sherepa
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: