Oracle Data dictionary is a place where Oracle stores information about some databases. Oracle Data Dictionary is mainly used to describe related data. For example, information about the creator of a table, creation time, tablespace, and user access permission.
Oracle Database Data dictionary is a set of tables and view structures. They are stored in the SYSTEM tablespace.
You can access the data dictionary to view detailed information when you encounter difficulties in performing operations on the data in the database.
You can use SQL statements to access the database data dictionary.
The Oracle Data dictionary includes:
1. Information about all schema objects in the database, such as tables, views, clusters, and indexes.
2. How much space is allocated and how much space is currently used.
3. Column default value.
4. Constraints on information integrity.
5. Oracle user name.
6. permissions granted to users and roles.
7. Audit information accessed or used by the user.
8. Other generated database information.
Data dictionaries in Oracle are static and dynamic.
1. static data dictionary --> it does not change when users access the data dictionary,
-- For example, a table created by a user
2. The dynamic data dictionary is dependent on the performance of the database and reflects some internal information about the database operation. Therefore, it is not always the same when accessing such data dictionaries.
-- The currently locked object
Static Data Dictionary: This type of data dictionary is mainly composed of tables and views.
The tables in the data dictionary cannot be directly accessed, but the views in the Oracle Data dictionary can be accessed.
The views in the static data dictionary are classified into three types:,
They are prefixed with user _ *, all _ *, and dba _*.
- user_*
This view stores information about the objects owned by the current user. All objects in this user mode)
- all_*
This attempt stores the information of objects accessible to the current user. Compared with user _ *, all _ * does not need to own this object. You only need to have the permission to access this object)
- dba_*
This view stores information about all objects in the database. The premise is that the current user has the permission to access these databases. Generally, the user must have the Administrator permission)
- select * from dictionary;
Query the tables owned by the user. user_tables describes the information of all the tables owned by the current user, including the table name, tablespace name, and cluster name. Through this view, you can clearly understand what tables can be operated by the current user
- desc user_tables;
- select table_name from user_tables;
- select * from user_tables;
Queries the indexes owned by the user.
- select index_name from user_indexes;
Query the views of a user.
- select view_name from user_views;
Queries the database objects owned by the user, including tables, views, stored procedures, triggers, packages, indexes, sequences, and JAVA files.
The above content is an introduction to the Oracle Data dictionary. I hope you will get something better.