GitHub user gatorsmile opened a pull request:
https://github.com/apache/spark/pull/17518
[SPARK-20198] [SQL] Remove the inconsistency when table/function name
definitions in SparkSession.Catalog APIs
### What changes were proposed in this pull request?
Observed by @felixcheung , in `SparkSession`.`Catalog` APIs, we have
different conventions/rules for table/function identifiers/names. Most APIs
accept the qualified name (i.e., `databaseName`.`tableName` or
`databaseName`.`functionName`). However, the following five APIs do not accept
it.
- def listColumns(tableName: String): Dataset[Column]
- def getTable(tableName: String): Table
- def getFunction(functionName: String): Function
- def tableExists(tableName: String): Boolean
- def functionExists(functionName: String): Boolean
To make them consistent with the other Catalog APIs, this PR does the
changes, updates the function/API comments and adds the `@params` to clarify
the inputs we allow.
### How was this patch tested?
Added the test cases .
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/gatorsmile/spark tableIdentifier
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/spark/pull/17518.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 #17518
----
commit 8581d5bd6c0acfdecd4d873ca85efcb02fc23e39
Author: Xiao Li <[email protected]>
Date: 2017-04-03T06:37:31Z
fix.
----
---
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]