Details
-
Type:
Bug
-
Status: Closed
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: 10.0.20
-
Component/s: Storage Engine - Connect
-
Labels:
-
Environment:Windows Server 2008R2, MS SQL Server 2012
Description
In 10.0.20 CONNECT will return the value NULL for rows that has value of 0 from SQL Server ODBC table from column of type decimal.
This did not happen in 10.0.17
I create a table on SQL Server and populate it with one row of value 0
create table t_dec_test(col1 decimal(10, 3)) insert into t_dec_test values (0)
Behavior in 10.0.20
Welcome to the MariaDB monitor. Commands end with ; or \g.
Your MariaDB connection id is 8
Server version: 10.0.20-MariaDB-log mariadb.org binary distribution
Copyright (c) 2000, 2015, Oracle, MariaDB Corporation Ab and others.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
MariaDB [(none)]> use util
Database changed
MariaDB [util]> create table t_dec_test
-> ENGINE=CONNECT CONNECTION='DSN=DEV;uid=user;pwd=password' `TABLE_TYPE`='ODBC'
-> \G
Query OK, 0 rows affected (0.09 sec)
MariaDB [util]> select * from t_dec_test\G
*************************** 1. row ***************************
col1: NULL
1 row in set (0.03 sec)
MariaDB [util]> show create table t_dec_test\G
*************************** 1. row ***************************
Table: t_dec_test
Create Table: CREATE TABLE `t_dec_test` (
`col1` decimal(12,3) DEFAULT NULL
) ENGINE=CONNECT DEFAULT CHARSET=latin1 COLLATE=latin1_general_ci CONNECTION='DSN=DEV;uid=user;pwd=password' `TABLE_TYPE`='ODBC'
1 row in set (0.00 sec)
MariaDB [util]>
Behavior in 10.0.17
Welcome to the MariaDB monitor. Commands end with ; or \g.
Your MariaDB connection id is 5
Server version: 10.0.17-MariaDB mariadb.org binary distribution
Copyright (c) 2000, 2015, Oracle, MariaDB Corporation Ab and others.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
MariaDB [(none)]> use util;
Database changed
MariaDB [util]> create table t_dec_test
-> ENGINE=CONNECT CONNECTION='DSN=DEV;uid=user;pwd=password' `TABLE_TYPE`='ODBC'\G
Query OK, 0 rows affected (0.06 sec)
MariaDB [util]> select * from t_dec_test\G
*************************** 1. row ***************************
col1: 0.000
1 row in set (0.04 sec)
MariaDB [util]> show create table t_dec_test\G
*************************** 1. row ***************************
Table: t_dec_test
Create Table: CREATE TABLE `t_dec_test` (
`col1` decimal(10,3) DEFAULT NULL
) ENGINE=CONNECT DEFAULT CHARSET=latin1 COLLATE=latin1_general_ci CONNECTION='DSN=DEV;uid=user;pwd=password' `TABLE_TYPE`='ODBC'
1 row in set (0.00 sec)
MariaDB [util]>
Gliffy Diagrams
Attachments
Activity
- All
- Comments
- Work Log
- History
- Activity
- Transitions
This was not specific to the SQL Server nor the decimal type. It concerned all ODBC tables.
It was a regression bug fixed by removing a wrong recent patch.