Github user felixcheung commented on a diff in the pull request:

    https://github.com/apache/spark/pull/17483#discussion_r109276366
  
    --- Diff: R/pkg/inst/tests/testthat/test_sparkSQL.R ---
    @@ -645,16 +645,17 @@ test_that("test tableNames and tables", {
       df <- read.json(jsonPath)
       createOrReplaceTempView(df, "table1")
       expect_equal(length(tableNames()), 1)
    -  tables <- tables()
    +  tables <- listTables()
    --- End diff --
    
    right, there are some differences of the output (most notability 
catalog.listTables returns a Dataset<Table> - but I'm converting that into a 
DataFrame anyway), and I thought list* would be more consistent with other 
methods like listColumn, listDatabases()
    
    ```
    > head(tables("default"))
      database tableName isTemporary
    1  default      json       FALSE
    Warning message:
    'tables' is deprecated.
    Use 'listTables' instead.
    See help("Deprecated")
    > head(listTables("default"))
      name database description tableType isTemporary
    1 json  default        <NA>  EXTERNAL       FALSE
    ```
    
    If you think it makes sense, we could make `tables` an alias of 
`listTables` - it's going to call slightly different code on the Scala side and 
there are new columns and one different column name being returned.



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

Reply via email to