cloud-fan opened a new pull request #24721: [SPARK-27856][SQL] do not forcibly add cast when inserting table URL: https://github.com/apache/spark/pull/24721 ## What changes were proposed in this pull request? When inserting data to a data source v1 table, Spark will forcibly cast the data type of input query to the data type of target table. This can be super confusing if users make a mistake and write string values to an int column. Users will get no error/warning and see null values in the target table. It's more reasonable to follow the behavior of data source v2 tables, which only allows "upcast", e.g. `int -> long`, `int -> string`, not `long -> int`, `string -> int`. ## How was this patch tested? new tests
---------------------------------------------------------------- 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: [email protected] With regards, Apache Git Services --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
