You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by "MaxGekk (via GitHub)" <gi...@apache.org> on 2023/05/18 20:33:18 UTC

[GitHub] [spark] MaxGekk opened a new pull request, #41221: [SPARK-43541][SQL][3.3] Propagate all `Project` tags in resolving of expressions and missing columns

MaxGekk opened a new pull request, #41221:
URL: https://github.com/apache/spark/pull/41221

   ### What changes were proposed in this pull request?
   In the PR, I propose to propagate all tags in a `Project` while resolving of expressions and missing columns in `ColumnResolutionHelper.resolveExprsAndAddMissingAttrs()`.
   
   This is a backport of https://github.com/apache/spark/pull/41204.
   
   ### Why are the changes needed?
   To fix the bug reproduced by the query below:
   ```sql
   spark-sql (default)> WITH
                      >   t1 AS (select key from values ('a') t(key)),
                      >   t2 AS (select key from values ('a') t(key))
                      > SELECT t1.key
                      > FROM t1 FULL OUTER JOIN t2 USING (key)
                      > WHERE t1.key NOT LIKE 'bb.%';
   [UNRESOLVED_COLUMN.WITH_SUGGESTION] A column or function parameter with name `t1`.`key` cannot be resolved. Did you mean one of the following? [`key`].; line 4 pos 7;
   ```
   
   ### Does this PR introduce _any_ user-facing change?
   No. It fixes a bug, and outputs the expected result: `a`.
   
   ### How was this patch tested?
   By new test added to `using-join.sql`:
   ```
   $ PYSPARK_PYTHON=python3 build/sbt "sql/testOnly org.apache.spark.sql.SQLQueryTestSuite -- -z using-join.sql"
   ```
   and the related test suites:
   ```
   $ build/sbt -Phive-2.3 -Phive-thriftserver "test:testOnly org.apache.spark.sql.hive.HiveContextCompatibilitySuite"
   ```
   
   Authored-by: Max Gekk <ma...@gmail.com>
   Signed-off-by: Max Gekk <ma...@gmail.com>
   (cherry picked from commit 09d5742a8679839d0846f50e708df98663a6d64c)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org


[GitHub] [spark] dongjoon-hyun closed pull request #41221: [SPARK-43541][SQL][3.3] Propagate all `Project` tags in resolving of expressions and missing columns

Posted by "dongjoon-hyun (via GitHub)" <gi...@apache.org>.
dongjoon-hyun closed pull request #41221: [SPARK-43541][SQL][3.3] Propagate all `Project` tags in resolving of expressions and missing columns
URL: https://github.com/apache/spark/pull/41221


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org


[GitHub] [spark] dongjoon-hyun commented on pull request #41221: [SPARK-43541][SQL][3.3] Propagate all `Project` tags in resolving of expressions and missing columns

Posted by "dongjoon-hyun (via GitHub)" <gi...@apache.org>.
dongjoon-hyun commented on PR #41221:
URL: https://github.com/apache/spark/pull/41221#issuecomment-1553845924

   Merged to branch-3.3.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org