Perhaps you could create a test case with table creation, upsert and then the 
select that reproduces and illustrates the problem?

Michael McAllister
Staff Data Warehouse Engineer | Decision Systems
[email protected]<mailto:[email protected]> | C: 512.423.7447 | 
skype: michael.mcallister.ha<mailto:[email protected]> | webex: 
https://h.a/mikewebex
[Description: Description: cid:3410354473_30269081]
This electronic communication (including any attachment) is confidential.  If 
you are not an intended recipient of this communication, please be advised that 
any disclosure, dissemination, distribution, copying or other use of this 
communication or any attachment is strictly prohibited.  If you have received 
this communication in error, please notify the sender immediately by reply 
e-mail and promptly destroy all electronic and printed copies of this 
communication and any attachment.

From: Marek Wiewiorka [mailto:[email protected]]
Sent: Monday, June 13, 2016 12:58 PM
To: [email protected]
Subject: Coalesce function returns nulls?

Hi All - I came across a very strange issue when using COALESCE function.
It appears to me that it returns null values - please consider a following 
query:
select length(coalesce(V_RS_DBSNP142,'N/A')) from TABLE1 limit 10;
+------------------------------------------+
| LENGTH(COALESCE("V_RS_DBSNP142", 'N/A')) |
+------------------------------------------+
| null                                     |
| null                                     |
| null                                     |
| null                                     |
| null                                     |
| null                                     |
| null                                     |
| null                                     |
| null                                     |
| null                                     |
+------------------------------------------+
10 rows selected (0.056 seconds)
Am I doing sth wrong or there is a bug in that function?
I'm using Phoenix 4.6.

Many thanks in advance.
Marek

Reply via email to