GitHub user vanzin opened a pull request: https://github.com/apache/spark/pull/16179
[SPARK-18752][hive] "isSrcLocal" value should be set from user query. The value of the "isSrcLocal" parameter passed to Hive's loadTable and loadPartition methods needs to be set according to the user query (e.g. "LOAD DATA LOCAL"), and not the current code that tries to guess what it should be. For existing versions of Hive the current behavior is probably ok, but some recent changes in the Hive code changed the semantics slightly, making code that sets "isSrcLocal" to "true" incorrectly to do the wrong thing. It would end up moving the parent directory of the files into the final location, instead of the file themselves, resulting in a table that cannot be read. Tested with existing unit tests and also ran some Hive integration tests with a version of Hive containing the changes that surfaced the problem. You can merge this pull request into a Git repository by running: $ git pull https://github.com/vanzin/spark SPARK-18752 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/spark/pull/16179.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #16179 ---- commit f1e09f44d2c5e8c613582e84647dcec5de0a5ff3 Author: Marcelo Vanzin <van...@cloudera.com> Date: 2016-12-06T22:44:03Z [SPARK-18752][hive] "isSrcLocal" value should be set from user query. The value of the "isSrcLocal" parameter passed to Hive's loadTable and loadPartition methods needs to be set according to the user query (e.g. "LOAD DATA LOCAL"), and not the current code that tries to guess what it should be. For existing versions of Hive the current behavior is probably ok, but some recent changes in the Hive code changed the semantics slightly, making code that sets "isSrcLocal" to "true" incorrectly to do the wrong thing. It would end up moving the parent directory of the files into the final location, instead of the file themselves, resulting in a table that cannot be read. ---- --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org