Details
-
Technical task
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Fixed
-
10.3(EOL)
-
None
Description
Earlier we made concatenation operator and SUBSTR translate empty results to NULL when running with sql_mode=ORACLE.
Under terms of this task we'll change TRIM, LTRIM, RTRIM to do the same.
The below scripts demonstrate Oracle's behavior:
SELECT
|
CASE |
WHEN TRIM('a' FROM 'aa') IS NULL THEN 'IS NULL' |
ELSE 'IS NOT NULL' |
END AS c |
FROM DUAL; |
C
|
-----------
|
IS NULL
|
SELECT
|
CASE |
WHEN LTRIM(' ') IS NULL THEN 'IS NULL' |
ELSE 'IS NOT NULL' |
END AS c |
FROM DUAL; |
C
|
-----------
|
IS NULL
|
SELECT
|
CASE |
WHEN RTRIM(' ') IS NULL THEN 'IS NULL' |
ELSE 'IS NOT NULL' |
END AS c |
FROM DUAL; |
C
|
-----------
|
IS NULL
|
Attachments
Issue Links
- relates to
-
MDEV-15739 sql_mode=ORACLE: Make LPAD and RPLAD return NULL instead of empty string
- Closed