What is database architecture?

A Database Architecture represents the Database Management System’s (DBMS) design (schema). The DBMS architecture makes it easy to understand the components involved in the database system and their relations. The DBMS architecture may vary based on the system on which it runs. Some systems contain both client and server machines whereas some run only on a server machine. Based on the architecture, the system can be classified as centralized, decentralized, or hierarchical.

Layers present in system architecture of an application

An application's system architecture contains one, two, and three up to N-Tiers. Tiers are also known as layers. There are mainly three types of layers in architecture: the presentation layer, application (business) layer, and data layer.  

A flowchart depicting the relation between the three layers and the database in a System Architecture.

Presentation Layer

The presentation layer is often referred to as the client and is the topmost layer in an application. The end-user has access to the application layer. This layer passes all the information that is given by the end-user. In simple terms, it is the application that we use. For instance, the login page of Facebook.

Application Layer

The application layer is also known as the business layer. It interacts with the end-user and sends the necessary details to the presentation layer. This layer acts as a mediator between the presentation and database layers. For instance, when the login button is clicked on the Facebook registration page, it passes the details to the presentation layer.

Data Layer

The data layer is the server. It communicates with the database layer to share and retrieve data. This layer contains the functions that connect with the database and performs actions such as insert, update, delete, search, and so on.   

Types of database architecture

The Database architecture varies depending on the computer system on which it operates. Users and applications cannot access or store data directly in a DBMS. The database can be stored at one location (centralized) or multiple locations (decentralized), or hierarchical based on its architecture.

The DBMS architecture design is based on the connection and how users interact with the database. Moreover, the architecture consists of clients and servers residing in the same system and connected through the internet connection. In other words, it can be a single or a multi-tier architecture.

The three types of database architectures based on their structure are:

  1. One-Tier Architecture
  2. Two-Tier Architecture
  3. Three-Tier Architecture 

One-tier architecture

One -Tier (Single-Tier) Architecture is the simplest DBMS architecture. In this type of architecture, the client, server, and database are available on the same machine. No internet connection is required to perform any action on the database. All the changes are reflected in the database directly. Additionally, single-tier architecture is also referred to as a local database system.

However, the response in One-Tier Architecture appears quicker, it is not ideal for the end-users. Hence, this architecture is often used by programmers and administrators. For instance, One-Tier architecture is installing a Database on the system and starts running SQL queries on it.

Two-tier architecture

A Two-Tier Architecture operates as a two-way system. The database system is stored on the server in this client-server architecture, and the DBMS application is on the client-side. Both of these machines are connected through a network. However, the client and server machines cannot communicate directly. To access the database on the server, the client has to make a request using a query language, that is, SQL. When the server receives the query, it acts and returns the result to the client. The communication between the application program and the database server is achieved using APIs such as ODBC, JDBC.

In this architecture, the DBMS is not exposed to the end-user directly. This ensures security to the DBMS. Also, the communication is faster and direct. A real-world 2-tier architecture can be exemplified by a Contact Management System made by MS Access.

2-tier Database Architecture - Client-Server model

Three-tier architecture

A Three-Tier Architecture is the widest used architecture. In this type of Architecture, an additional layer, known as the Application Layer, sits between the client (presentation layer) and the server (database) machine. This application layer offers a Graphical User Interface (GUI), making it easy for the end-user to interact with the database. In brief, the application layer handles the communication between the client and server.

A Three-tier Architecture contains the following three layers:

  • Database Layer: This layer contains the database and operates using query processing languages like DML, DDL. The relations and the constraints of the stored data are defined here.
  • Application/ Middle Layer (the server): The application tier acts as a communicator, mediator, or gateway between the end-user and the database. It provides an interface using which the end-user can access the database. It stores the connectivity software and controls the data that is transferred. Before sending any data to the User or DBMS, the application layer processes functional logic and constraint on it.
  • Presentation Layer (User Interface): This is the layer through which the end-user accesses the database. The end-users can see tables or views and provide any data using an application. The changes made are independent as the components available at this layer are independent. Hence, none of them will be aware of each other’s activities. The application layer manages both the end-users and backend.

The three-tier architecture supports multiple data views. Here, the users handle programming data independently and separate user applications from physical applications. A three-tier architecture can be exemplified by the PHP My Admin used in My SQL.

N-tier architecture

The DBMS architecture with multiple layers is called an N-Tier Architecture (also known as Multi-Tier architecture). The layers of such architectures are separated to handle the processing, data management, and presentation functions independently.

Multi-Tier architectures have the following three tiers:

  1. Presentation tier
  2. Logic tier
  3. Data-tier

A closer look into each tier 

1. Presentation Tier

The Presentation-Tier is the topmost tier in the DBMS architecture. It is the user interface through which the end-user accesses the database. This layer translates the tasks and displays the results of the user’s query such that it is easily understandable. 

2. Logic Tier

The Logic-Tier is responsible for coordinating the tasks between the presentation and data tiers. It processes the functions, queries, commands, performs logical decisions, and calculations. This tier acts as a gateway between the surrounding layers.

3. Data Tier

The Data-Tier possesses the actual information. This tier stores and retrieves the information from the database server such as My SQL, No SQL. When the end-user runs a command, it goes to the logic tier and then reaches the data tier. This tier then processes the action and returns the result to the logic tier, which then sends it to the end-user.

Common Mistakes

Database architecture and data models are two different concepts. Data architecture deals with the framework that transfers data between two components. The data model defines the relationship between various data elements. These two terms are often confused.

  • Database
  • Three-schema architecture
  • RDBMS
  • DBMS data models

Context and Applications

This topic is essential in Database Management System studies. Even competitive examinations ask questions based on the types of database architecture.

  • Bachelors in Computer Science
  • Masters in Computer Science
  • Masters of Science in Analytics

Practice Problem

Ques 1) What is the intermediate layer between database and client servers in a three-tier architecture called?

  1. Data Structure Layer
  2. Application Layer
  3. Functional Layer
  4. Presentation Layer

Ans: Option b

Explanation:- The three-tier architecture has three layers: the presentation layer, application layer, and data layer. The presentation layer is called client-server and the data layer is called the database and both layers communicate through the intermediate layer called the application layer.

Ques 2) In what type of DBMS architecture does an application residing in the client machine invoke database system functionality at the server-side using a query statement?

  1. One-Tier Architecture
  2. Two-Tier Architecture
  3. Three-Tier Architecture
  4. None

Ans: Option b

Explanation:- In the two-tier architecture, the client interacts with the database stored on the server through query languages such as SQL, NoSQL.

Ques 3) How can a database architecture be viewed?

  1. One level
  2. Two-level
  3. Three-level
  4. Multi-level

Ans: Option c

Explanation:-Database architecture is viewed as three levels of data abstraction called internal, external, and conceptual levels.

Ques 4) Which layer decides what action should be done under a certain condition?

  1. Data Layer
  2. Business Layer
  3. OLTP Layer
  4. Presentation Layer

Ans: Option b

Explanation:- The business layer takes the command from the user and sends it to the database to fetch data based on the request done by the end-user.

Ques 5) Which query processing language does the client-server use to access the database server?

  1. SQL
  2. NoSQL
  3. MongoDB
  4. Hadoop

Ans: Option a

Explanation:- SQL (structured Query Language) is the widely used query language that is used to operate databases.  

 

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

Database

Database architectures

Types of Database Architectures

Types of database architectures Homework Questions from Fellow Students

Browse our recently answered Types of database architectures homework questions.

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

Database

Database architectures

Types of Database Architectures