ReyYang opened a new issue, #14601:
URL: https://github.com/apache/shardingsphere/issues/14601
Use Sharding-proxy to query bit type data, the returned result column is
empty
### Which version of ShardingSphere did you use?
master branch
MySQL 5.6,5.7
### Which project did you use? ShardingSphere-JDBC or ShardingSphere-Proxy?
ShardingSphere-Proxy
### Expected behavior
"bit" column returns normally
### Actual behavior
"bit" column returns empty
### Reason analyze (If you can)
The bit type is not judged when SQL parsing returns
### Steps to reproduce the behavior, such as: SQL to execute, sharding rule
configuration, when exception occur etc.
```sql
-- create table
create table table_numeric
(
id bigint
primary key,
shard_id bigint not null,
t_int int null,
t_sint smallint not null,
t_ting tinyint null,
t_mint mediumint null,
t_bint bigint null,
t_decimal decimal null,
t_numeric decimal null,
t_float float null,
t_double double null,
t_bit bit null,
t_real double null
);
-- insert datas
insert into table_numeric (id, shard_id, t_int, t_sint, t_ting,
t_mint, t_bint, t_decimal,
t_numeric, t_float, t_double,
t_bit, t_real)
VALUES (1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1),
(2, 3, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1, 2),
(3, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 0, 3),
(4, 5, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, 4),
(5, 6, 5, 5, 5, 5, 5, 5, 5, 5, 5, 0, 5),
(6, 4, 6, 6, 6, 6, 6, 6, 6, 6, 6, 1, 6);
```
use Sharding-Proxy select data
```shell
mysql> select * from table_numeric;
+----+----------+-------+--------+--------+--------+--------+-----------+-----------+---------+----------+-------+--------+
| id | shard_id | t_int | t_sint | t_ting | t_mint | t_bint | t_decimal |
t_numeric | t_float | t_double | t_bit | t_real |
+----+----------+-------+--------+--------+--------+--------+-----------+-----------+---------+----------+-------+--------+
| 6 | 4 | 6 | 6 | 6 | 6 | 6 | 6 |
6 | 6.0 | 6.0 | | 6.0 |
| 3 | 2 | 3 | 3 | 3 | 3 | 3 | 3 |
3 | 3.0 | 3.0 | | 3.0 |
| 5 | 6 | 5 | 5 | 5 | 5 | 5 | 5 |
5 | 5.0 | 5.0 | | 5.0 |
| 2 | 3 | 2 | 2 | 2 | 2 | 2 | 2 |
2 | 2.0 | 2.0 | | 2.0 |
| 4 | 5 | 4 | 4 | 4 | 4 | 4 | 4 |
4 | 4.0 | 4.0 | | 4.0 |
| 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 |
1 | 1.0 | 1.0 | | 1.0 |
+----+----------+-------+--------+--------+--------+--------+-----------+-----------+---------+----------+-------+--------+
```
### Example codes for reproduce this issue (such as a github link).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail:
[email protected]
For queries about this service, please contact Infrastructure at:
[email protected]