edb_redwood_strings v14
In Oracle, when a string is concatenated with a null variable or null column, the result is the original string. However, in PostgreSQL, concatenation of a string with a null variable or null column gives a null result. If the edb_redwood_strings
parameter is set to TRUE
, the concatenation operation results in the original string as done by Oracle. If edb_redwood_strings
is set to FALSE
, the native PostgreSQL behavior is maintained.
The following example illustrates the difference.
The sample application contains a table of employees. This table has a column named comm
that's null for most employees. The following query is run with edb_redwood_string
set to FALSE
. The concatenation of a null column with non-empty strings produces a final result of null, so only employees that have a commission appear in the query result. The output line for all other employees is null.
The following is the same query executed when edb_redwood_strings
is set to TRUE
. Here, the value of a null column is treated as an empty string. The concatenation of an empty string with a non-empty string produces the non-empty string. This result is consistent with the results produced by Oracle for the same query.