@snippet
def dataset_list_tables(client, to_delete):
 DATASET_NAME = ('dataset_list_tables_dataset_%d' % (_millis(),))
 TABLE_NAME = ('dataset_list_tables_table_%d' % (_millis(),))
 dataset = client.dataset(DATASET_NAME)
 dataset.create()
 to_delete.append(dataset)
 tables = list(dataset.list_tables())
 assert (len(tables) == 0)
 table = dataset.table(TABLE_NAME)
 table.view_query = QUERY
 table.create()
 tables = list(dataset.list_tables())
 assert (len(tables) == 1)
 assert (tables[0].name == TABLE_NAME)
 to_delete.insert(0, table)

@ snippet def dataset_list_tables ( client , to_delete ) : DATASET_NAME = ( 'dataset_list_tables_dataset_%d' % ( _millis ( ) , ) ) TABLE_NAME = ( 'dataset_list_tables_table_%d' % ( _millis ( ) , ) ) dataset = client . dataset ( DATASET_NAME ) dataset . create ( ) to_delete . append ( dataset ) tables = list ( dataset . list_tables ( ) ) assert ( len ( tables ) == 0 ) table = dataset . table ( TABLE_NAME ) table . view_query = QUERY table . create ( ) tables = list ( dataset . list_tables ( ) ) assert ( len ( tables ) == 1 ) assert ( tables [ 0 ] . name == TABLE_NAME ) to_delete . insert ( 0 , table )
list tables within a dataset .