phoenix-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sachin (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (PHOENIX-4728) ARRAY_APPEND and ARRAY_REMOVE should work with null column value
Date Fri, 01 Mar 2019 16:27:00 GMT

    [ https://issues.apache.org/jira/browse/PHOENIX-4728?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16781844#comment-16781844
] 

Sachin commented on PHOENIX-4728:
---------------------------------

In older versions, you may still do ARRAY_CAT(ARRAY['New value'], COLUMN) , this works even
when COLUMN is null.

> ARRAY_APPEND and ARRAY_REMOVE should work with null column value
> ----------------------------------------------------------------
>
>                 Key: PHOENIX-4728
>                 URL: https://issues.apache.org/jira/browse/PHOENIX-4728
>             Project: Phoenix
>          Issue Type: Bug
>    Affects Versions: 4.14.0
>            Reporter: Xavier Jodoin
>            Assignee: Xavier Jodoin
>            Priority: Major
>             Fix For: 5.0.0, 4.15.0
>
>
> ARRAY_APPEND and ARRAY_REMOVE should create the array value when it's null
> Test case:
> create table test_array (
> ID VARCHAR NOT NULL,
> MYARRAY VARCHAR ARRAY
> CONSTRAINT testpk PRIMARY KEY (ID)
> );
> upsert into test_array (id) values ('test');
> upsert into test_array select id,array_append(myarray,'testValue') from test_array;
> select ID,ARRAY_TO_STRING(MYARRAY, ',')  from test_array;
>  
>  



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

Mime
View raw message