Skip to content

Conversation

wecharyu
Copy link
Contributor

What changes were proposed in this pull request?

Introduce a new SQL to enable unset SERDE properties:

ALTER TABLE table_identifier partition_spec UNSET SERDEPROPERTIES [ IF EXISTS ] ( key1, key2, ... )

Why are the changes needed?

Spark SQL already supports SET SERDEPROPERTIES, it would be more convenient if we can use UNSET SERDEPROPETIES

Does this PR introduce any user-facing change?

Yes, user can use this new SQL.

How was this patch tested?

Add unit tests:

./build/mvn  test -Dtest=none -Dsuites="org.apache.spark.sql.execution.command.AlterTableUnsetSerdePropertiesParserSuite" -pl :spark-sql_2.13
./build/mvn  test -Dtest=none -Dsuites="org.apache.spark.sql.execution.command.v1.AlterTableUnsetSerdePropertiesSuite" -pl :spark-sql_2.13
./build/mvn  test -Dtest=none -Dsuites="org.apache.spark.sql.hive.execution.command.AlterTableUnsetSerdePropertiesSuite" -pl :spark-hive_2.13
./build/mvn  test -Dtest=none -Dsuites="org.apache.spark.sql.execution.command.v2.AlterTableUnsetSerdePropertiesSuite" -pl :spark-sql_2.13

Was this patch authored or co-authored using generative AI tooling?

No.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant