GitHub user cloud-fan opened a pull request:
https://github.com/apache/spark/pull/16332
[SPARK-18921][SQL] check database existence with Hive.databaseExists
instead of getDatabase
## What changes were proposed in this pull request?
It's weird that we use `Hive.getDatabase` to check the existence of a
database, while Hive has a `databaseExists` interface.
What's worse, `Hive.getDatabase` will produce an error message if the
database doesn't exist, which is annoying when we only want to check the
database existence.
This PR fixes this and use `Hive.databaseExists` to check database
existence.
## How was this patch tested?
N/A
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/cloud-fan/spark minor
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/spark/pull/16332.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 #16332
----
commit b1b152b0cb94c1f6b0a41ee3f13750d96c3420a0
Author: Wenchen Fan <[email protected]>
Date: 2016-12-19T03:19:32Z
check database existence with Hive.databaseExists instead of getDatabase
----
---
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 [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]