What is a database?
Learn why applications use organized systems to store and retrieve information.
A college portal needs to remember students, courses, and enrollments. A shopping app needs products, orders, and delivery details. These applications need more than a temporary variable: they need information that can be stored, found, updated, and used consistently. A database is a system designed to manage that information.
Data needs structure and rules
In a relational database, information is commonly organized into tables. A Students table might contain one row per student, while a Courses table contains one row per course. Each row represents a record, and columns describe properties such as a name or course code. A unique identifier helps distinguish one record from another.
Tables can be connected. An Enrollments table might link a student identifier to a course identifier. This avoids repeating all the student's details every time they enroll in a new course. The database can also enforce rules—for example, an enrollment must refer to a student and a course that actually exist.
A database is not just a spreadsheet
A spreadsheet is useful for people to inspect and edit a small set of tabular information. A database system is built to support software access, larger workloads, controlled permissions, concurrent users, and consistent updates. Some databases are relational and use tables; others organize data as documents, key-value pairs, graphs, or other structures.
Queries ask for information
An application sends a query to ask the database for records or to change them. In a relational database, SQL is a widely used language for expressing those queries. The application often communicates with the database through a server or API rather than allowing a user's browser to connect directly to the database.
What to remember
- A database manages information so software can store, retrieve, and update it.
- Different database types organize information in different ways.
- Identifiers and relationships help connect records consistently.
- Applications commonly access databases through a controlled server-side layer.
Keep following what you understand. This article is part of a growing knowledge library; related topics can help you explore the ideas around it.