VeloDB Cloud
SQL Manual
Statments
Show-Statements
SHOW-TABLES

SHOW-TABLES

Name

SHOW TABLES

Description

This statement is used to display all tables under the current db

Syntax:

SHOW TABLES [LIKE]

Note:

  1. LIKE: to perform fuzzy query based on table names

Example

  1. View all tables under DB

    mysql> show tables;
    +---------------------------------+
    | Tables_in_demo                  |
    +---------------------------------+
    | ads_client_biz_aggr_di_20220419 |
    | cmy1                            |
    | cmy2                            |
    | intern_theme                    |
    | left_table                      |
    +---------------------------------+
    5 rows in set (0.00 sec)
  2. Fuzzy query by table name

    mysql> show tables like '%cm%';
    +----------------+
    | Tables_in_demo |
    +----------------+
    | cmy1           |
    | cmy2           |
    +----------------+
    2 rows in set (0.00 sec)

Keywords

SHOW, TABLES

Best Practice