[
https://issues.apache.org/jira/browse/PHOENIX-4728?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16487998#comment-16487998
]
ASF GitHub Bot commented on PHOENIX-4728:
-----------------------------------------
Github user xjodoin commented on the issue:
https://github.com/apache/phoenix/pull/301
No the problem come from the querycompiler for the upsertselect the
behavior is different than a simple select query
Le 23 mai 2018 16:04:46 HAE, James Taylor <[email protected]> a
écrit :
>JamesRTaylor commented on this pull request.
>
>
>
>> @@ -549,7 +549,7 @@ public MutationPlan compile(UpsertStatement
>upsert) throws SQLException {
> select = SelectStatement.create(select, hint);
>// Pass scan through if same table in upsert and select so that
>projection is computed correctly
> // Use optimizer to choose the best plan
>- QueryCompiler compiler = new QueryCompiler(statement,
>select, selectResolver, targetColumns, parallelIteratorFactoryToBe, new
>SequenceManager(statement), false, false, null);
>+ QueryCompiler compiler = new QueryCompiler(statement,
>select, selectResolver, targetColumns, parallelIteratorFactoryToBe, new
>SequenceManager(statement), true, false, null);
>
>This seems like too general of a change for the specific issue you're
>trying to fix for ARRAY_APPEND. I'm also not sure *why* it would impact
>it. Can't you make changes to ArrayAppendFunction or it's base class to
>get the desired affect?
>
>Any opinions, @maryannxue. Do you remember when/why we need this
>projectTuples boolean for QueryCompiler?
>
>--
>You are receiving this because you authored the thread.
>Reply to this email directly or view it on GitHub:
>https://github.com/apache/phoenix/pull/301#pullrequestreview-122745792
--
Envoyé de mon appareil Android avec K-9 Mail. Veuillez excuser ma brièveté.
> 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
> Priority: Major
>
> 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)