TcaplusDB Client - Show Command

For TcaplusDB Client Instructions, see Document.

1. Function Descriptions

Show tables can query all data table names in the currently connected TcaplusDB.

Show status can query the current connection status, directory server information and access layer information.

Show shard can query shard ids of the table, if use where clause, show shard id of the record in table

Show last_access_time can query last_access_time of the record in table, only generic tables are supported.

2. Initial Version

3.40.0

3. Command Syntax

show [tables/status];

Parameter description:

Parameter Description
tables Query all data table names in the currently connected TcaplusDB
status Query the current server status and configuration information
shard Query shard ids of the table, if use where clause, show shard id of the record in table.
last_access_time Query last_access_time of the record in table, only generic tables are supported.

4. Command Example

tcaplus> help show;
--------------------------------------------------------------------------------
show tables    output all table names
show status    output appID, zoneID, dir server status, tcaproxy status,
               all the dir server addresses

show shard from <table> [where key1=*** and key2=***](full key)
               show shard ids of the table, if use where clause, show shard id of the record in table.

show last_access_time from <table> where key1=*** and key2=*** (full key)
               show last_access_time of the record in table, only generic tables are supported.
--------------------------------------------------------------------------------

tcaplus> show tables;

----------------------------------------------------------
| Table Name                         Type      Protocol  |
----------------------------------------------------------
| test_table                         GENERIC   TDR       |
| tbMailTest                         LIST      PROTOBUF  |
| pb_generic_index_shardingkey       GENERIC   PROTOBUF  |
| pb_generic_index_noshardkey        GENERIC   PROTOBUF  |
| pb_generic_noindex_noshardkey      GENERIC   PROTOBUF  |
| pb_list                            LIST      PROTOBUF  |
| pb_list2                           LIST      PROTOBUF  |
| pb_sortedlist                      LIST      PROTOBUF  |
| aes_info                           GENERIC   TDR       |
| auth_info                          GENERIC   TDR       |
| depend_me_services                 GENERIC   TDR       |
| host_info                          GENERIC   TDR       |
| instance_info                      GENERIC   TDR       |
| node_info                          GENERIC   TDR       |
| service_depends                    GENERIC   TDR       |
| service_info                       GENERIC   TDR       |
| token_info                         GENERIC   TDR       |
| cl_list                            LIST      PROTOBUF  |
| cl_generic                         GENERIC   PROTOBUF  |
| table_generic                      GENERIC   TDR       |
----------------------------------------------------------

tcaplus> show status;

------------------------------------------------------------------
Access_id(app_id) = 2
------------------------------------------------------------------
TableGroup_id(zone_id) = 3
------------------------------------------------------------------
[dir_server_url]
                 dir_server_url[0]: 9.135.8.93:9999
------------------------------------------------------------------
[Proxys]
                 proxy[0]:tcp://9.135.8.93:13755 CONNECTED Authened
                 proxy[1]:tcp://9.135.8.93:13756 CONNECTED Authened
------------------------------------------------------------------
[The connected dir server]
                 tcp://9.135.8.93:9999
------------------------------------------------------------------

tcaplus> show shard from IDAllocc;
shard id: 7224852
------------------------------------------------------------------

tcaplus> show shard from IDAllocc where IDType=1;
shard id: 7224852
------------------------------------------------------------------

tcaplus> show last_access_time from IDAllocc where IDType=1;
last_access_time: 1746500784
------------------------------------------------------------------

results matching ""

    No results matching ""