What is data dictionary?

A database management system has an entity-relationship diagram, data dictionary, and data model as some of its key components, which are tools for the users who are managing the database. One of them is the data dictionary. The data dictionary can also be called metadata. By definition, metadata is a generic concept in the world of information and technology. An example of metadata could be meta-information about a media file or an image file, like author, location, last updated, size, etc. The contents of a data dictionary are names, attributes, and properties of main data elements which are captured during an experiment or stored in an information system, for example, databases. We can also call it a central repository of information about the main data.

A data dictionary provides details about things like:

  • Meanings of objects
  • Relationship between the data objects
  • Views
  • Origin of the data elements
  • Format of the data elements

The data dictionary concept is used in various domains like DBMS (database management systems), software engineering, etc. In DBMS, for example, in oracle, the content of the data dictionary is metadata about structures and blueprint of tables:

  • Name of the tables
  • Definition of each column of every table
  • Constraints like key relationships
  • Ownership and privileges granted on the tables and other database objects
  • Statistics like last accessed or last updated
  • Indexes used by the optimizer
Sample figure showing the content of Data Dictionary
Content of Data Dictionary

EXAMPLE:
Let's understand the concept of a Data dictionary with the help of an example.
Say, we have a relation Student as shown below.

Fields of relation Student
Fields of relation Student


The Data Dictionary for the above fields is given below.

The figure representing the Data dictionary
The figure representing the Data dictionary

Types of data dictionary

  1. Active
  2. Passive

Active data dictionary

If the fields of the database change in between the running system, then the update should be reflected in the data dictionary also. Active data dictionary updates automatically through background running tasks. Because of that, we do not use any external software for managing the data dictionary.

Passive data dictionary

Database administrators modify a passive data dictionary. Since it is updated manually, managing the files becomes an important task. The file is stored separately from the database. The passive data dictionary is not a part of a database management system. This type of data dictionary is not directly associated with any database or server.
In the field of software engineering, the data dictionary is used as a tool to gather requirements from business owners. It helps in bridging the gap between business owners and technical teams in the process of database designing and modeling. The data dictionary is used mainly by users and database designers. Data description specification (DDS) is to describe data attributes in the data dictionary that are different from an application software that uses data directly or indirectly.

Functions of the data dictionary

  • It helps all the users to know about the objects of the Database as the users do not know about whole database tables, views, and constraints. If the user wants any database object information from the Database, then the user can put a query on the data dictionary.
  • If any DDL (data definition language) is put on data objects, then the object looks into the data dictionary. Then, the internal DBMS software modifies the object depending on DDL. These modifications are reflected on the main tables and also the user view.
  • It controls the accessibility of different objects of the Database by means of its views. As different user has different permissions to see the parts of the Database.
  • It consists of a quick and well-managed report on data objects.
  • It ensures that all the database tables have to be up-to-date all the time.

Components or Elements of Data Dictionary

Data Dictionary contains:-

  • Data flow- It shows the path of data from source to destination to process final reports. Each Dataflow should consist of descriptive information.
  • Data Structures- Data structures are represented by using an algebraic notation that shows the group of smaller structures and elements. Data structures can be either physical or logical. The physical data structure includes information and elements important to implement the system. Logical data structure shows the composition of data used by the user.
  • Elements- Elements are descriptive information such as type of data information and length, Default Values, and validation criteria. Each element should be defined once in the dictionary.
  • Datastores- It consists of all base elements as well as derived elements. It is created for each and every entity. Datastores are created for each group also.

Data Dictionary Notations

Data Dictionary contains or uses these notations.

Data Dictionary notations

Let's see this with the help of an example:-

  • Composition:

Name=First_name+Last_name

  • Sequence: 

      Mailing-address = name + address(House Number) + city + zip-code

The customer's mailing address is where he or she receives mail.

  • Repetition:

      Completed-order = {item-ordered}

The complete customer order.

  • Selection: 

Atm_transaction = [ deposit | withdrawal ]

The customer transaction at an ATM.

  • Comment:

*A complete customer order*

Advantages of data dictionary

  • As the data is stored in one file, it helps to reduce the data redundancy as we know which column to access for change or use.
  • It helps to build transparency between different teams by bringing everyone on the same page and reducing dependency on team members.
  • This provides help in reusing the column values.
  • This provides help in the analysis of the data as all the fields are described in one file.
  • Improves data quality, improves decision making.
  • Helps in documenting the data.
  • It helps to understand the database for new joiners or new database users.
  • All the information is assembled in one place as databases are huge and have a number of tables.

Disadvantages of data dictionary

  • The data dictionary is only for technical users as all the information is about the database only.
  • The making of a data dictionary is a very difficult task as well as costly.
  • If the data dictionary commits a mistake initially, then it becomes a difficult task to correct it.
  • As dictionary is for all the database users, there are access restrictions on the dictionary.

Common Mistakes

  • The data dictionary is different from the database. It does not contain tables. It only contains information about the tables and resources if any data table is inherited from somewhere.
  • The data dictionary is a document that manages data objects.
  • The data dictionary is created when we create a new database.
  • RDBMS
  • DBMS

Context and Applications

This topic is essential in the professional exams for both graduate and postgraduate courses, especially for:

  • B. Tech in Computer Science
  • M. Tech in Computer Science
  • Master of Computer Application

Practice Problems

Q1. How many types of data dictionaries are there?

a. Active and Passive

b. Active and Inactive

c. DDL and DML

d. Object and Views

Correct answer: a.

Explanation:- There are two types of data dictionaries. Active and passive data dictionary. Active data dictionary updates automatically. A passive data dictionary is manually updated by database administrators.

Q2. If data objects change automatically in tables, it is called

a. Active data dictionary

b. Passive data dictionary

c. Both a and b

d. None

Correct answer: Active

Explanation:-There are two types of a data dictionary. Active and passive data dictionary. Active data dictionary updates automatically.

Q3. Does the data dictionary has tables of the objects.

a) True

b) false

Correct answer: True

Explanation: A table in the data dictionary has row items that are database table properties, and the column name is the description.

Q4. Who is making the Data dictionary?

a. Software developer

b. Database administrator

c. Client

d. Both Software developer and Database administrator

Correct answer: Both software developer and Database administrator

Explanation:- Data Dictionary is made by both software developers and database administrators.

Q5. When a __________ is formed, a data dictionary is created as well.

a. Table

b. Schema

c. Database

d. None

Correct answer: Database

Explanation:- A database management system has an entity-relationship diagram, data dictionary, and data model as some of its key components, which are tools for the users who are managing the database.

Want more help with your computer science homework?

We've got you covered with step-by-step solutions to millions of textbook problems, subject matter experts on standby 24/7 when you're stumped, and more.
Check out a sample computer science Q&A solution here!

*Response times may vary by subject and question complexity. Median response time is 34 minutes for paid subscribers and may be longer for promotional offers.

Search. Solve. Succeed!

Study smarter access to millions of step-by step textbook solutions, our Q&A library, and AI powered Math Solver. Plus, you get 30 questions to ask an expert each month.

Tagged in
EngineeringComputer Science

System Design

Modeling Data

Data Dictionary

Search. Solve. Succeed!

Study smarter access to millions of step-by step textbook solutions, our Q&A library, and AI powered Math Solver. Plus, you get 30 questions to ask an expert each month.

Tagged in
EngineeringComputer Science

System Design

Modeling Data

Data Dictionary