Important
Helios features are now enabled during weekly update windows and are no longer directly tied to SingleStore engine releases. Refer to the release notes to view the latest features available in your Helios cluster.
SHOW TABLES
On this page
The SHOW TABLES command shows the list of tables in the currently selected database, or in another database if specified.
Syntax
SHOW [FULL] [TEMPORARY] TABLES [{FROM | IN} db_name]
[[EXTENDED] LIKE pattern | WHERE TABLE_TYPE {= | !=} {'VIEW' | 'BASE TABLE'}]Remarks
-
db_is the name of a SingleStore Helios database.name If db_is not specified, then a database must be currently selected (see USE ).name -
The
SHOW TABLEScommand (without theTEMPORARYoption) run on the child or master aggregator displays the global temporary tables and normal tables, but not the temporary tables. -
SHOW TEMPORARY TABLESwill show temporary tables but not global temporary tables. -
If you specify a table type, you must also use the
FULLkeyword. -
See the Permission Matrix for the required permission.
Examples
Example 1
Suppose a global temporary table globtemp and a temporary table temptab exists in the database, along with few normal tables.
SHOW TABLES;
+---------------+
| Tables_in_db1 |
+---------------+
| allviews |
| circle |
| globtemp |
| product |
| reading |
| source |
| stock |
| stockN |
+---------------+SHOW TEMPORARY TABLES;
+---------------+------------+------------+
| Tables_in_db1 | aggregator | connection |
+---------------+------------+------------+
| temptab | 1 | 5 |
+---------------+------------+------------+Example 2
SHOW TABLES EXTENDED;
+---------------+------------------------+-------------+-------------------+
| Tables_in_db1 | Table_type | distributed | Storage_type |
+---------------+------------------------+-------------+-------------------+
| allviews | BASE TABLE | 1 | INMEMORY_ROWSTORE |
| circle | BASE TABLE | 1 | INMEMORY_ROWSTORE |
| globtemp | GLOBAL TEMPORARY TABLE | 1 | INMEMORY_ROWSTORE |
| product | BASE TABLE | 1 | INMEMORY_ROWSTORE |
| reading | BASE TABLE | 1 | INMEMORY_ROWSTORE |
| source | BASE TABLE | 1 | INMEMORY_ROWSTORE |
| stock | BASE TABLE | 1 | INMEMORY_ROWSTORE |
| stockN | BASE TABLE | 1 | INMEMORY_ROWSTORE |
| temptab | TEMPORARY TABLE | 1 | INMEMORY_ROWSTORE |
+---------------+------------------------+-------------+-------------------+Example 3
SHOW TABLES LIKE 's%';
+--------------------+
| Tables_in_db1 (s%) |
+--------------------+
| source |
| stock |
| stockN |
+--------------------+Example 4
SHOW FULL TABLES WHERE TABLE_TYPE = 'BASE TABLE';
+---------------+------------+
| Tables_in_db1 | Table_type |
+---------------+------------+
| allviews | BASE TABLE |
| circle | BASE TABLE |
| product | BASE TABLE |
| reading | BASE TABLE |
| source | BASE TABLE |
| stock | BASE TABLE |
| stockN | BASE TABLE |
+---------------+------------+Last modified: