All Products
Search
Document Center

Tablestore:List tables

Last Updated:Aug 11, 2026

Use the Tablestore SDK for Go to list all tables in the current instance.

Prerequisites

Install the Tablestore SDK for Go and initialize the client.

Description

Call ListTable to query the names of all tables in the current instance. This method does not require request parameters.

func (tableStoreClient *TableStoreClient) ListTable() (*ListTableResponse, error)

The following sample lists all tables in the current instance.

response, err := client.ListTable()
if err != nil {
    log.Fatal(err)
}

for _, tableName := range response.TableNames {
    fmt.Println(tableName)
}

Response

ListTableResponse contains the following business information.

Field

Type

Description

TableNames

[]string

The names of the tables in the current instance.