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

ASF subversion and git services commented on ASTERIXDB-3301:
------------------------------------------------------------

Commit 8149d01b423192c8aa9487ae1e62094fd3f93e22 in asterixdb's branch 
refs/heads/master from Ali Alsuliman
[ https://gitbox.apache.org/repos/asf?p=asterixdb.git;h=8149d01b42 ]

[ASTERIXDB-3301][COMP] NPE for subquery with only SELECT ELEMENT

- user model changes: no
- storage format changes: no
- interface changes: no

Details:
When a subquery consists of only SELECT ELEMENT, a NullPointerException
is encountered. The exception is due to the fact that the base/input
operator for the SUBPLAN of the subquery starts with a 'null' op that
gets replaced by a NTS op later after translating the subquery. This
works fine, but when the subquery is only a SELECT ELEMENT
expression, there are no intermediate operators translated and therefore
the root op of the subplan tries to reference the input op directly which
is 'null' at the time.

Change-Id: I5b314c014798daf4890f75998138954e3d858445
Reviewed-on: https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/17928
Integration-Tests: Jenkins <[email protected]>
Reviewed-by: Wail Alkowaileet <[email protected]>
Tested-by: Jenkins <[email protected]>


> NPE for subquery with only SELECT ELEMENT
> -----------------------------------------
>
>                 Key: ASTERIXDB-3301
>                 URL: https://issues.apache.org/jira/browse/ASTERIXDB-3301
>             Project: Apache AsterixDB
>          Issue Type: Bug
>          Components: COMP - Compiler
>            Reporter: Ali Alsuliman
>            Assignee: Ali Alsuliman
>            Priority: Major
>
> The below query causes NullPointerException:
> {noformat}
> FROM [1,2,3] a
> LET test = (SELECT RAW a)
> SELECT a, test;
> {noformat}



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to