code: def tableNames(self, dbName=None):
          
          if dbName is None:
              return [name for name in self._ssql_ctx.tableNames()]
          else:
              return [name for name in self._ssql_ctx.tableNames(dbName)]
docs: Returns a list of names of tables in the database ``dbName``.
  
          :param dbName: string, name of the database to use. Default to the current database.
          :return: list of table names, in string
  
          >>> sqlContext.registerDataFrameAsTable(df, "table1")
          >>> "table1" in sqlContext.tableNames()
          True
          >>> "table1" in sqlContext.tableNames("default")
          True