-
Notifications
You must be signed in to change notification settings - Fork 29k
[SPARK-37950][SQL] Take EXTERNAL as a reserved table property #35268
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
Conversation
docs/sql-migration-guide.md
Outdated
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.
| - Since Spark 3.3, the property `external` become reserved for table; commands fail if you specify `external` property in places like `CREATE TABLE ... TBLPROPERTIES` and `ALTER TABLE ... SET TBLPROPERTIES`. You can set `spark.sql.legacy.notReserveProperties` to `true` to ignore the `ParseException`, in this case, `external` will be silently removed. | |
| - Since Spark 3.3, the table property `external` becomes reserved. Certain commands will fail if you specify the `external` property, such as `CREATE TABLE ... TBLPROPERTIES` and `ALTER TABLE ... SET TBLPROPERTIES`. In Spark 3.2 and earlier, the table property `external` is silently ignored. You can set `spark.sql.legacy.notReserveProperties` to `true` to restore the old behavior. |
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.
| PROP_EXTERNAL, ctx, "it will be set according the location") | |
| PROP_EXTERNAL, ctx, "please use CREATE EXTERNAL TABLE") |
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.
I think 'External'='bar' still works?
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.
yeah. 'External'='bar' still works. EXTERNAL is the key word of the hive metastore.
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.
then let's use External and keep this test.
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.
ok.
|
thanks, merging to master! |
What changes were proposed in this pull request?
Take
externalas a reserved table property. and do not allow useexternalfor end-user whenspark.sql.legacy.notReserveProperties==false.Why are the changes needed?
#disscuss.
keep it consistent with other properties like
locationownerproviderand so on.Does this PR introduce any user-facing change?
Yes. end-user could not use
externalas property key when create table with tblproperties and alter table set tblproperties.How was this patch tested?
existed testcase.