Home > Database > Oracle > How to query how many tables there are in oracle

How to query how many tables there are in oracle

WBOY
Release: 2022-02-17 17:57:57
Original
11154 people have browsed it

In Oracle, you can use the select statement with "count (*)" to query how many tables there are. This statement can display the number of all tables in the database. The syntax is "select count (*) from user_tables; ".

How to query how many tables there are in oracle

The operating environment of this tutorial: Windows 10 system, Oracle 11g version, Dell G3 computer.

How to query how many tables there are in oracle

Query the total number of tables under the current user.

After logging in to the sys user, check the number of tables under the current user through the user_tables table.

conn / as sysdba;

select count(*) from user_tables ;
Copy after login

Explanation: After logging in to the system as a super user, read the number of rows recorded in the "user table" through the above sql (each table There will be one record), which is the number of tables under the current database.

Examples are as follows:

How to query how many tables there are in oracle

Recommended tutorial: "Oracle Video Tutorial"

The above is the detailed content of How to query how many tables there are in oracle. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template