MaxGekk opened a new pull request #27057: [SPARK-29930][SQL][FOLLOW-UP] Allow 
only default value to be set for removed SQL configs
URL: https://github.com/apache/spark/pull/27057
 
 
   ### What changes were proposed in this pull request?
   In the PR, I propose to throw `AnalysisException` when a removed SQL config 
is set to non-default value. The following SQL configs removed by #26559 are 
marked as removed:
   1. `spark.sql.fromJsonForceNullableSchema`
   2. `spark.sql.legacy.compareDateTimestampInTimestamp`
   3. `spark.sql.legacy.allowCreatingManagedTableUsingNonemptyLocation`
   
   ### Why are the changes needed?
   To improve user experience with Spark SQL by notifying of removed SQL 
configs used by users.
   
   ### Does this PR introduce any user-facing change?
   Yes, before the `set` command was silently ignored:
   ```sql
   spark-sql> set spark.sql.fromJsonForceNullableSchema=false;
   spark.sql.fromJsonForceNullableSchema        false
   ```
   after the exception should be raised:
   ```sql
   spark-sql> set spark.sql.fromJsonForceNullableSchema=false;
   Error in query: The SQL config 'spark.sql.fromJsonForceNullableSchema' was 
removed in the version 3.0.0.;
   ```
   
   ### How was this patch tested?
   Added new tests into `SQLConfSuite` for both cases when removed SQL configs 
are set to default and non-default values.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

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

Reply via email to