DATA DICTIONARY
-- set of read only tables, provide info about the database
-- contains - definition of all schema objects (tables, views, indexes, sequences, synonyms, functions, procs, packages, clusters etc.)
>> how much space is allocated to and is used by a schema object
>> integrity constraints
>> default values of the columns
>> names of the users, their privileges and roles
>> who accessed and updated which db object
>> other general db related info
data dictionary is structured in tables and views. It is stored in the SYSTEM tablespace of a database.
It consists of : BASE TABLES - which store all the db related info. user access to these tables is not advised, and only Oracle database should access these tables. Most info stored in these tables is in cryptic form.
USER-ACCESSIBLE VIEWS - summarize the info stored in BASE TABLES into userful informative views. Most of the views are intended for every user, but there are few which are for administrators only.
These views are grouped into 3 classes -
DBA_ - These views have some additional info for database administrators
ALL_ - accessible to all users, contains objects to which the user has privileges
USER_ - accessible to all users, contains objects owned by the user
The system supplied view DICTIONARY has names and desc of all the data dictionary views.
******
select OBJECT_NAME from USER_OBJECTS
WHERE object_type = 'TABLE'
This query will give the list of all the user tables in the schema.
******
select * from ALL_OBJECTS
WHERE object_type = 'TABLE'
This query will give all the tables , user created as well as Oracle supplied like DUAL.
-- set of read only tables, provide info about the database
-- contains - definition of all schema objects (tables, views, indexes, sequences, synonyms, functions, procs, packages, clusters etc.)
>> how much space is allocated to and is used by a schema object
>> integrity constraints
>> default values of the columns
>> names of the users, their privileges and roles
>> who accessed and updated which db object
>> other general db related info
data dictionary is structured in tables and views. It is stored in the SYSTEM tablespace of a database.
It consists of : BASE TABLES - which store all the db related info. user access to these tables is not advised, and only Oracle database should access these tables. Most info stored in these tables is in cryptic form.
USER-ACCESSIBLE VIEWS - summarize the info stored in BASE TABLES into userful informative views. Most of the views are intended for every user, but there are few which are for administrators only.
These views are grouped into 3 classes -
DBA_ - These views have some additional info for database administrators
ALL_ - accessible to all users, contains objects to which the user has privileges
USER_ - accessible to all users, contains objects owned by the user
The system supplied view DICTIONARY has names and desc of all the data dictionary views.
******
select OBJECT_NAME from USER_OBJECTS
WHERE object_type = 'TABLE'
This query will give the list of all the user tables in the schema.
******
select * from ALL_OBJECTS
WHERE object_type = 'TABLE'
This query will give all the tables , user created as well as Oracle supplied like DUAL.