[MCOL-4044] Built In SQL Functions not working with sql_mode=ORACLE Created: 2020-06-05  Updated: 2021-11-18  Resolved: 2021-05-05

Status: Closed
Project: MariaDB ColumnStore
Component/s: None
Affects Version/s: None
Fix Version/s: 5.6.1

Type: Bug Priority: Major
Reporter: Todd Stoffel (Inactive) Assignee: Daniel Lee (Inactive)
Resolution: Fixed Votes: 1
Labels: None

Issue Links:
Duplicate
is duplicated by MCOL-4587 sql_mode=ORACLE specific functions do... Closed
Relates
relates to MDEV-10342 Providing compatibility for basic SQL... Closed
Sprint: 2021-3, 2021-4, 2021-5, 2021-6, 2021-7

 Description   

Some basic sql functions such as:

TRIM
CONCAT
REPLACE
ENCODE
DECODE

are not working in ColumnStore when the server is set to sql_mode=Oracle

MariaDB [(none)]> create database tests;
Query OK, 1 row affected (0.001 sec)
 
MariaDB [(none)]> use tests;
Database changed
 
MariaDB [tests]> create table foo (id INT, myname varchar(30))engine = innodb;
Query OK, 0 rows affected (0.012 sec)
 
MariaDB [tests]> create table bar (id INT, myname varchar(30))engine = columnstore;
Query OK, 0 rows affected (0.285 sec)
 
MariaDB [tests]> INSERT INTO foo VALUES (1,'Monty Widenius');
Query OK, 1 row affected (0.003 sec)
 
MariaDB [tests]> INSERT INTO bar VALUES (1,'Monty Widenius');
Query OK, 1 row affected (15.549 sec)
 
MariaDB [tests]> SET SESSION sql_mode=ORACLE;
Query OK, 0 rows affected (0.000 sec)
 
MariaDB [tests]> SELECT CONCAT(id,myname) FROM foo;
+-------------------+
| CONCAT(id,myname) |
+-------------------+
| 1Monty Widenius     |
+-------------------+
1 row in set (0.001 sec)
 
MariaDB [tests]> SELECT CONCAT(id,myname) FROM bar;
+-------------------+
| CONCAT(id,myname) |
+-------------------+
| 1                 |
+-------------------+
1 row in set (0.073 sec)



 Comments   
Comment by Daniel Lee (Inactive) [ 2021-05-05 ]

Build verified: 5.6.1 ( Drone #2325 )

Verified all mentioned functions return same result as InnoDB.

Generated at Thu Feb 08 02:47:22 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.