LIST TABLES
Use LIST TABLES to list all tables in the database that match the specification provided with the command argument. Use the DBLOGIN command to establish a database connection before using this command. If logging into an Oracle multitenant container database, log in to the pluggable database that contains the tables that you want to list.
If you want to list all the tables that are enabled for auto capture, then use the auto_capture option. This option is only valid for Oracle Database 21c or higher. You need to establish a database connection (using DBLOGIN command) before using this command. If you are unable to establish a connection or don’t have the required privileges, the option will not work.
Syntax
LIST TABLES *table*
The following syntax applies when using the auto_capture option.
LIST TABLES [*container.*]*owner.table* [AUTO_CAPTURE]
table
The name of a table or a group of tables specified with a wildcard (*).
[container.]owner.table
The command accepts a two-part name in non-CDB mode and a three-part name in CDB mode. Supported wildcards are ? and * for single and zero or more character matching respectively. In Admin Client, both the schema/owner and container name cannot contain a wildcard character. Table name can have wildcards. When the command is successful, the output shows the list of tables enabled for auto capture matching the input criteria.
Example
The following shows a LIST TABLES command and sample output.
LIST TABLES empl*
Example
The following example shows a LIST TABLES command listing tables enabled for auto capture:
LIST TABLES hr.emp* AUTO_CAPTURE
The output is similar to the following:
2022-09-06T06:31:09Z INFO OGG-15189 Default catalog name DBEAST will be used for table specification hr.emp*.
"DBEAST"."HR"."EMPLOYEES"
"DBEAST"."HR"."EMP_DETAILS_VIEW"
Found 2 tables matching list criteria.