-
Notifications
You must be signed in to change notification settings - Fork 29.3k
[SPARK-30019][SQL] Add the owner property to v2 table #27249
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 13 commits
6708db6
30b91f5
e9ade41
0467b1e
4577e93
0b50979
0fc2692
f5512fb
8e4f747
e618825
46ae85b
c04082b
9bb78eb
ce352a9
8e70ec1
97f07b8
6b48061
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -2680,6 +2680,10 @@ class AstBuilder(conf: SQLConf) extends SqlBaseBaseVisitor[AnyRef] with Logging | |
| throw new ParseException(s"$PROP_LOCATION is a reserved table property, please use" + | ||
| s" the LOCATION clause to specify it.", ctx) | ||
| case (PROP_LOCATION, _) => false | ||
| case (PROP_OWNER, _) if !legacyOn => | ||
| throw new ParseException(s"$PROP_OWNER is a reserved table property , please use" + | ||
| " ALTER TABLE ... SET OWNER ... to specify it.", ctx) | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. it can't be changed after table is created. |
||
| case (PROP_OWNER, _) => false | ||
| case _ => true | ||
| } | ||
| } | ||
|
|
@@ -3621,5 +3625,4 @@ class AstBuilder(conf: SQLConf) extends SqlBaseBaseVisitor[AnyRef] with Logging | |
| ctx.ownerType.getText) | ||
| } | ||
| } | ||
|
|
||
| } | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -36,6 +36,7 @@ import org.apache.spark.sql.catalyst.expressions.{Attribute, AttributeReference} | |
| import org.apache.spark.sql.catalyst.plans.DescribeTableSchema | ||
| import org.apache.spark.sql.catalyst.plans.logical._ | ||
| import org.apache.spark.sql.catalyst.util.{escapeSingleQuotedString, quoteIdentifier, CaseInsensitiveMap} | ||
| import org.apache.spark.sql.connector.catalog.TableCatalog | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. unnecessary change |
||
| import org.apache.spark.sql.execution.datasources.{DataSource, PartitioningUtils} | ||
| import org.apache.spark.sql.execution.datasources.csv.CSVFileFormat | ||
| import org.apache.spark.sql.execution.datasources.json.JsonFileFormat | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -19,6 +19,7 @@ package org.apache.spark.sql | |
|
|
||
| import org.apache.spark.sql.catalyst.TableIdentifier | ||
| import org.apache.spark.sql.catalyst.catalog.CatalogTable | ||
| import org.apache.spark.sql.connector.catalog.TableCatalog | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. unnecessary |
||
| import org.apache.spark.sql.test.{SharedSparkSession, SQLTestUtils} | ||
| import org.apache.spark.util.Utils | ||
|
|
||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it's reserved for both table and namespace, or do I miss something?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nvm, we can update when revert ALTER NAMESPACE SET OWNER.