You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@phoenix.apache.org by "James Taylor (JIRA)" <ji...@apache.org> on 2018/03/07 15:52:00 UTC

[jira] [Resolved] (PHOENIX-4638) string length function returns null for empty string.

     [ https://issues.apache.org/jira/browse/PHOENIX-4638?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

James Taylor resolved PHOENIX-4638.
-----------------------------------
    Resolution: Not A Bug

Phoenix treats an empty string as null (like Oracle) and the string length of null is null.

> string length function returns null for empty string.
> -----------------------------------------------------
>
>                 Key: PHOENIX-4638
>                 URL: https://issues.apache.org/jira/browse/PHOENIX-4638
>             Project: Phoenix
>          Issue Type: Bug
>    Affects Versions: 4.13.2-cdh5.11.2
>            Reporter: Clive Stellings
>            Priority: Major
>
> When you execute length('') at the prompt it returns null when it should probably return 0.
> e.g.
> 0: jdbc:phoenix:localhost:2181:/hbase>select length('');
> -------+
>  |       |
> -------+
> | null |
>  -------+
>  row selected (0.006 seconds)
>  : jdbc:phoenix:localhost:2181:/hbase>



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)