GitHub user bbejeck opened a pull request:

    https://github.com/apache/spark/pull/3872

    Spark 3299 add to SQLContext API to show tables

    SPARK-3299 Add to the SQLContext the ability to show tables, updated the 
Catalog, OverrideCatalog Traits, SimpleCatalog class, EmptyCatalog object, 
SQLContext class and the HiveMetastoreCatalog class.  Added tests in 
ListTablesSuite.  The method 'showTables' has been added, takes one parameter 
of type Optional[String] used for designating a database.  I tried to include 
the HiveMetastoreCatalog class in the unit testing but was unsuccessful in 
being able to get a test to run.  I will follow up on the developer list with 
questions on how to do this and update accordingly.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/bbejeck/spark 
spark-3299-SQLContext-list_tables

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/spark/pull/3872.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 #3872
    
----
commit 90f5c980143350769ff2aeaf7393e3318d5bc1f1
Author: Bill Bejeck <[email protected]>
Date:   2014-12-21T03:33:57Z

    SPARK-3299 added a listTables method to the Catalog trait, implementations 
to SimpleCatalog, OverrideCatalog and EmptyCatalog.  Added method listTables in 
SQLContext that delegates to the SimpleCatalog instance

commit 80632a7752b16a9089c1e002156f1286edf8493d
Author: Bill Bejeck <[email protected]>
Date:   2014-12-29T19:51:47Z

    Initial implementation of listTables method

commit ce0eab8b7552c6b71df3e1c7633cbe8a42a3c2ad
Author: Bill Bejeck <[email protected]>
Date:   2014-12-29T21:25:59Z

    SPARK-3299 changed listTables method to take an Option for database name, 
updated all classes overriding the method.

commit ee499077ab7c6d6a215a3e10808d0726ab6e55ec
Author: Bill Bejeck <[email protected]>
Date:   2014-12-30T02:56:31Z

    SPARK-3299 changed abstract listTable method to return immutable list, made 
the listTables method for OverrideCatalog take case into account, provide 
option for using database name

commit 1612d64a80b2b7d42814f4717799a3f516f5f0c1
Author: Bill Bejeck <[email protected]>
Date:   2014-12-30T03:34:37Z

    SPARK-3299 updated listTables to take case into account, simplified code

commit 904327b31ac139692e80836eaecc0f84a6f8621a
Author: Bill Bejeck <[email protected]>
Date:   2014-12-31T03:26:11Z

    SPARK-3299 unit tests for listTables functionality

commit d25afc50e78fddb8f4ef588346be4daf7652fefc
Author: Bill Bejeck <[email protected]>
Date:   2015-01-01T03:47:35Z

    SPARK-3299 added test for EmptyCatalog

commit 1886d6f721e17222d6632669e743e089f3e3bda0
Author: Bill Bejeck <[email protected]>
Date:   2015-01-01T03:57:51Z

    SPARK-3299 refactored method name from listTables to showTables

commit 0bac19135f1087de22a116708b356cac5e895966
Author: Bill Bejeck <[email protected]>
Date:   2015-01-01T04:06:00Z

    SPARK-3299 added Apache license header, removed comment

commit cfa8fe48675c0de2351cb79f9d5e125975981a73
Author: Bill Bejeck <[email protected]>
Date:   2015-01-01T12:56:50Z

    SPARK-3299 changed matcher expectation to allOf from theSameElementsAs 
TestSQLContext is a singleton across all tests

commit c5609faec0647332243151ab7513ccdc04893f46
Author: Bill Bejeck <[email protected]>
Date:   2015-01-01T13:01:11Z

    SPARK-3299 Add to the SQLContext the ability to show tables, updated the 
Catalog, OverrideCatalog Traits, SimpleCatalog class, EmptyCatalog object, 
SQLContext class and the HiveMetastoreCatalog class.  Added tests in 
ListTablesSuite.  The method 'showTables' has been added, takes one parameter 
of type Optional[String] used for designating a database.

----


---
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]

Reply via email to