[IOTDB-2974] It is recommended to use double quotation marks or quotation marks to insert data in the TEXT type.
An exception is thrown for insertion of TEXT types that that is not quoted or double quoted.
Before:
IoTDB> set storage group to root.ln;
set storage group to root.ln;
Msg: The statement is executed successfully.
IoTDB> create timeseries root.ln.wf01.wt01.temperature with datatype=FLOAT,encoding=RLE;
create timeseries root.ln.wf01.wt01.temperature with datatype=FLOAT,encoding=RLE;
Msg: The statement is executed successfully.
IoTDB> create timeseries root.ln.wf01.wt01.hardware with datatype=Text,encoding=PLAIN;
create timeseries root.ln.wf01.wt01.hardware with datatype=Text,encoding=PLAIN;
Msg: The statement is executed successfully.
IoTDB> show timeseries root.ln.;
show timeseries root.ln.;
+-----------------------------+-----+-------------+--------+--------+-----------+----+----------+
| timeseries|alias|storage group|dataType|encoding|compression|tags|attributes|
+-----------------------------+-----+-------------+--------+--------+-----------+----+----------+
|root.ln.wf01.wt01.temperature| null| root.ln| FLOAT| RLE| SNAPPY|null| null|
| root.ln.wf01.wt01.hardware| null| root.ln| TEXT| PLAIN| SNAPPY|null| null|
+-----------------------------+-----+-------------+--------+--------+-----------+----+----------+
Total line number = 2
It costs 0.076s
IoTDB> insert into root.ln.wf01.wt01(timestamp, hardware) values(2,1)
insert into root.ln.wf01.wt01(timestamp, hardware) values(2,1)
Msg: The statement is executed successfully.
IoTDB> insert into root.ln.wf01.wt01(timestamp, hardware) values(3,false)
insert into root.ln.wf01.wt01(timestamp, hardware) values(3,false)
Msg: The statement is executed successfully.
IoTDB> insert into root.ln.wf01.wt01(timestamp, hardware) values(4,'a')
insert into root.ln.wf01.wt01(timestamp, hardware) values(4,'a')
Msg: The statement is executed successfully.
IoTDB> select hardware from root.ln.wf01.wt01;
select hardware from root.ln.wf01.wt01;
+-----------------------------+--------------------------+
| Time|root.ln.wf01.wt01.hardware|
+-----------------------------+--------------------------+
|1970-01-01T08:00:00.002+08:00| 1|
|1970-01-01T08:00:00.003+08:00| false|
|1970-01-01T08:00:00.004+08:00| a|
+-----------------------------+--------------------------+
Total line number = 3
It costs 2.893s
IoTDB>

After:
IoTDB> set storage group to root.ln;
set storage group to root.ln;
Msg: The statement is executed successfully.
IoTDB> create timeseries root.ln.wf01.wt01.temperature with datatype=FLOAT,encoding=RLE;
create timeseries root.ln.wf01.wt01.temperature with datatype=FLOAT,encoding=RLE;
Msg: The statement is executed successfully.
IoTDB> create timeseries root.ln.wf01.wt01.hardware with datatype=Text,encoding=PLAIN;
create timeseries root.ln.wf01.wt01.hardware with datatype=Text,encoding=PLAIN;
Msg: The statement is executed successfully.
IoTDB> show timeseries root.ln.;
show timeseries root.ln.;
+-----------------------------+-----+-------------+--------+--------+-----------+----+----------+
| timeseries|alias|storage group|dataType|encoding|compression|tags|attributes|
+-----------------------------+-----+-------------+--------+--------+-----------+----+----------+
|root.ln.wf01.wt01.temperature| null| root.ln| FLOAT| RLE| SNAPPY|null| null|
| root.ln.wf01.wt01.hardware| null| root.ln| TEXT| PLAIN| SNAPPY|null| null|
+-----------------------------+-----+-------------+--------+--------+-----------+----+----------+
Total line number = 2
It costs 0.414s
IoTDB> insert into root.ln.wf01.wt01(timestamp, hardware) values(2,1)
insert into root.ln.wf01.wt01(timestamp, hardware) values(2,1)
Msg: 313: failed to insert measurements [hardware] caused by The data type of TEXT should be a sequence of bytes or characters, enclosed within either single quote (') or double quote (") characters.
IoTDB> insert into root.ln.wf01.wt01(timestamp, hardware) values(3,false)
insert into root.ln.wf01.wt01(timestamp, hardware) values(3,false)
Msg: 313: failed to insert measurements [hardware] caused by The data type of TEXT should be a sequence of bytes or characters, enclosed within either single quote (') or double quote (") characters.
IoTDB> insert into root.ln.wf01.wt01(timestamp, hardware) values(4,'a')
insert into root.ln.wf01.wt01(timestamp, hardware) values(4,'a')
Msg: The statement is executed successfully.
IoTDB> insert into root.ln.wf01.wt01(timestamp, hardware) values(5,"b")
insert into root.ln.wf01.wt01(timestamp, hardware) values(5,"b")
Msg: The statement is executed successfully.
IoTDB> select hardware from root.ln.wf01.wt01;
select hardware from root.ln.wf01.wt01;
+-----------------------------+--------------------------+
| Time|root.ln.wf01.wt01.hardware|
+-----------------------------+--------------------------+
|1970-01-01T08:00:00.004+08:00| a|
|1970-01-01T08:00:00.005+08:00| b|
+-----------------------------+--------------------------+
Total line number = 2
It costs 0.696s
IoTDB>

Hi, some tests failed, PTAL.
Hi, some tests failed, PTAL.
Let me see!
These tests failed because the previous ones involved TEXT tests that did not use quotes.