Skip to main content

SHOW TABLET

Description

This statement is used to show details of a specific tablet (only for administrators).

Syntax

SHOW TABLET <tablet_id>;

Required Parameters

1. <tablet_id>

The ID of the specific tablet to display information for.

Return Value

When using SHOW TABLET <tablet_id>, the following columns are returned:

ColumnDataTypeNote
DbNameStringThe name of the database that contains the tablet.
TableNameStringThe name of the table that contains the tablet.
PartitionNameStringThe name of the partition that contains the tablet.
IndexNameStringThe name of the index that contains the tablet.
DbIdIntThe ID of the database.
TableIdIntThe ID of the table.
PartitionIdIntThe ID of the partition.
IndexIdIntThe ID of the index.
IsSyncBooleanWhether the tablet is in sync with its replicas.
OrderIntThe order of the tablet.
QueryHitsIntThe number of query hits on this tablet.
DetailCmdStringThe command to get more detailed information about the tablet.

Access Control Requirements

The user executing this SQL command must have at least the following privileges:

PrivilegeObjectNotes
Admin_privDatabaseRequired to execute administrative operations on the database, including managing tables, partitions, and system-level commands.

Examples

Show details of a specific tablet:

SHOW TABLET 10145;
+--------+-----------+---------------+-----------+-------+---------+-------------+---------+--------+-------+-----------+------------------------------------------------------------+
| DbName | TableName | PartitionName | IndexName | DbId | TableId | PartitionId | IndexId | IsSync | Order | QueryHits | DetailCmd |
+--------+-----------+---------------+-----------+-------+---------+-------------+---------+--------+-------+-----------+------------------------------------------------------------+
| test | sell_user | sell_user | sell_user | 10103 | 10143 | 10142 | 10144 | true | 0 | 0 | SHOW PROC '/dbs/10103/10143/partitions/10142/10144/10145'; |
+--------+-----------+---------------+-----------+-------+---------+-------------+---------+--------+-------+-----------+------------------------------------------------------------+