Database
Database Concepts #
- A collection of data integrated and managed for use by multiple people, systems, or programs.
- With the development of IT systems, effective management of rapidly increasing data has become crucial.
Eliminating redundancy,ensuring integrity,maintaining consistency, andguaranteeing usabilityof data are core aspects of database management.
Database Characteristics #
- Real-time Accessibility
- Continuous Evolution
- Concurrent Sharing
- Content Reference
Database Design Order #
Requirements Analysis > Conceptual Design > Logical Design > Physical Design > Implementation
Database Terminology #
- Attribute: Refers to a single column within a relation, representing and storing an entity. It is often expressed as a
columnorfield. - Tuple: Refers to a single row within a relation, and is sometimes expressed as a
recordorrow. - Degree: Refers to the number of attributes contained within a single relation.
- Cardinality: Refers to the number of tuples contained within a single relation.
- Domain: Refers to the set of values that each attribute within a relation can take.
- View: A virtual table derived from one or more base tables, whose structure and operations are very similar to those of base tables.
Schema #
Refers to the overall specification regarding the structure and constraints of a database.
- Internal Schema (Physical): The database defined from the perspective of system programmers or designers.
- Conceptual Schema (Logical): The database defined from the perspective of an institution or organization, based on the data users need.
- External Schema (Subschema): The database needed from the individual perspective of users.
Key #
Keyfunctions as a unique identifier for identifying something.- Candidate Key: A set of attributes that satisfy
uniquenessandminimality. - Primary Key: A key selected from candidate keys, where
duplicate values cannot be enteredandNull values are not allowed. - Super Key: A set of attributes that satisfy
uniquenessbutdo not satisfy minimality. - Alternate Key: Candidate keys that were not chosen as the primary key.
- Foreign Key: A key that identifies a row in another table.
Uniqueness
The property of unique data that allows a specific row to be found directly using a single key.
Database Management System (DBMS) #
- It is software that resolves the complexity of data management as described above,
while simultaneously supporting functionssuch asdata addition,modification,deletion,backup,recovery, andsecurity. - The stored information is highly diverse, including text, images, music files, and map data.
DBMS Pros and Cons #
Pros- Minimizing data redundancy
- Data sharing (maintaining consistency)
- Maintaining consistency, integrity, and security
- User-centric data processing
- Applicability of data standardization
- Easy data access
- Savings due to shared data storage space
Cons- Requires database specialists (DBA)
- Need for DBMS server setup and maintenance costs
- Difficulty in data backup and recovery
- System complexity
- Overload due to bottleneck when access is concentrated on large-capacity disks
- Difficulty in processing large volumes of data
- Candidate Key: A set of attributes that satisfy
Database Administrator (DBA) #
- Rather than directly utilizing the database, they design and build it for users, and manage and control it to ensure proper service.
- Key responsibilities of a Database Administrator
- Selection of database components
- Definition of database schema
- Determination of physical storage structure and access methods
- Definition of constraints for maintaining integrity
- Decision on security and access control policies
- Definition of backup and recovery techniques
- Management of system databases
- System performance monitoring and analysis
- Database reorganization