Impala Public Jenkins has submitted this change and it was merged. ( http://gerrit.cloudera.org:8080/19426 )
Change subject: IMPALA-11840: Error with joining unnest with views ...................................................................... IMPALA-11840: Error with joining unnest with views Queries fail in the following situation involving collections and views: 1. A view returns an array 2. A second view unnests the array returned from the first view 3. The unnested view is queried in an outer query For example: use functional_parquet; with sub as ( select id, arr1.item unnested_arr from complextypes_arrays_only_view, complextypes_arrays_only_view.int_array arr1) select id, unnested_arr from sub; ERROR: IllegalStateException: null The problem is that in CollectionTableRef.analyze(), if - there is a source view and - the collection ref is within a WITH clause and - it is not in the select list then 'desc_' is not set, but it has to be set in order for TableRef.analyzeJoin() to succeed. This commit solves the problem by assigning a value to 'desc_' also in the above case. Testing: - Added regression tests in nested-types-runtime.test. Change-Id: Ic52655631944913553a7e7d9e9169b93da46dde3 Reviewed-on: http://gerrit.cloudera.org:8080/19426 Reviewed-by: Impala Public Jenkins <impala-public-jenk...@cloudera.com> Tested-by: Impala Public Jenkins <impala-public-jenk...@cloudera.com> --- M fe/src/main/java/org/apache/impala/analysis/CollectionTableRef.java M testdata/workloads/functional-query/queries/QueryTest/nested-types-runtime.test 2 files changed, 104 insertions(+), 19 deletions(-) Approvals: Impala Public Jenkins: Looks good to me, approved; Verified -- To view, visit http://gerrit.cloudera.org:8080/19426 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-MessageType: merged Gerrit-Change-Id: Ic52655631944913553a7e7d9e9169b93da46dde3 Gerrit-Change-Number: 19426 Gerrit-PatchSet: 5 Gerrit-Owner: Daniel Becker <daniel.bec...@cloudera.com> Gerrit-Reviewer: Csaba Ringhofer <csringho...@cloudera.com> Gerrit-Reviewer: Daniel Becker <daniel.bec...@cloudera.com> Gerrit-Reviewer: Impala Public Jenkins <impala-public-jenk...@cloudera.com> Gerrit-Reviewer: Peter Rozsa <pro...@cloudera.com>