SuccessChanges

Summary

  1. [SPARK-30431][SQL] Update SqlBase.g4 to create commentSpec pattern like (details)
  2. [SPARK-30173] Tweak stale PR message (details)
  3. [SPARK-30039][SQL] CREATE FUNCTION should do multi-catalog resolution (details)
Commit 8c121b0827495342592c6ad978a10fbf934620e2 by wenchen
[SPARK-30431][SQL] Update SqlBase.g4 to create commentSpec pattern like
locationSpec
### What changes were proposed in this pull request?
In `SqlBase.g4`, the `comment` clause is used as `COMMENT
comment=STRING` and `COMMENT STRING` in many places.
While the `location` clause often appears along with the `comment`
clause with a pattern defined as
```sql locationSpec
   : LOCATION STRING
   ;
``` Then, we have to visit `locationSpec` as a `List` but comment as a
single token.
We defined `commentSpec` for the comment clause to simplify and unify
the grammar and the invocations.
### Why are the changes needed?
To simplify the grammar.
### Does this PR introduce any user-facing change?
no
### How was this patch tested?
existing tests
Closes #27102 from yaooqinn/SPARK-30431.
Authored-by: Kent Yao <yaooqinn@hotmail.com> Signed-off-by: Wenchen Fan
<wenchen@databricks.com>
The file was modifiedsql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/parser/AstBuilder.scala (diff)
The file was modifiedsql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/parser/ParserUtilsSuite.scala (diff)
The file was modifiedsql/core/src/main/scala/org/apache/spark/sql/execution/SparkSqlParser.scala (diff)
The file was modifiedsql/catalyst/src/main/antlr4/org/apache/spark/sql/catalyst/parser/SqlBase.g4 (diff)
Commit f399d655c4f960646701d6feda578ee97705de99 by srowen
[SPARK-30173] Tweak stale PR message
Follow-on to #26877.
### What changes were proposed in this pull request?
This PR tweaks the stale PR message to
[clarify](https://github.com/apache/spark/pull/24457#issuecomment-571393900)
the procedure for reopening a PR after it has been marked as stale.
### Why are the changes needed?
This change should clarify the reopening process for contributors.
### Does this PR introduce any user-facing change?
No.
### How was this patch tested?
N/A
Closes #27114 from nchammas/SPARK-30173-stale-tweaks.
Authored-by: Nicholas Chammas <nicholas.chammas@gmail.com>
Signed-off-by: Sean Owen <srowen@gmail.com>
The file was modified.github/workflows/stale.yml (diff)
Commit 9479887ba1f4c9f8503bee9ed90a03dab525f246 by wenchen
[SPARK-30039][SQL] CREATE FUNCTION should do multi-catalog resolution
### What changes were proposed in this pull request?
Add CreateFunctionStatement and make CREATE FUNCTION go through the same
catalog/table resolution framework of v2 commands.
### Why are the changes needed?
It's important to make all the commands have the same table resolution
behavior, to avoid confusing CREATE FUNCTION namespace.function
### Does this PR introduce any user-facing change?
Yes. When running CREATE FUNCTION namespace.function Spark fails the
command if the current catalog is set to a v2 catalog.
### How was this patch tested?
Unit tests.
Closes #26890 from planga82/feature/SPARK-30039_CreateFunctionV2Command.
Authored-by: Pablo Langa <soypab@gmail.com> Signed-off-by: Wenchen Fan
<wenchen@databricks.com>
The file was modifiedsql/core/src/test/scala/org/apache/spark/sql/execution/command/DDLParserSuite.scala (diff)
The file was modifiedsql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/parser/DDLParserSuite.scala (diff)
The file was modifiedsql/core/src/main/scala/org/apache/spark/sql/catalyst/analysis/ResolveSessionCatalog.scala (diff)
The file was modifiedsql/core/src/test/scala/org/apache/spark/sql/connector/DataSourceV2SQLSuite.scala (diff)
The file was modifiedsql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/plans/logical/statements.scala (diff)
The file was modifiedsql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/parser/AstBuilder.scala (diff)
The file was modifiedsql/core/src/main/scala/org/apache/spark/sql/execution/SparkSqlParser.scala (diff)