Databases and Database Users
CHAPTER 1: Databases and Database Users
Basic Definitions
Database: A collection of related data organized in a manner that facilitates easy access, management, and updating.
Data: Known facts that can be recorded and have an implicit meaning (e.g., numbers representing age, text strings representing names).
Mini-world: A specific part of the real world about which data is stored within a database. For example, the mini-world of student grades and transcripts at a university.
Database Management System (DBMS): A software package or system designed to facilitate the creation, structure, management, and maintenance of computerized databases.
Database System: The combination of the DBMS software and the data itself. In some definitions, application programs are included along with the DBMS and data.
Types of Databases and Database Applications
Traditional Applications: Includes numeric and textual databases.
More Recent Applications:
Multimedia Databases: Store and manage non-text data such as images and videos.
Geographic Information Systems (GIS): Manage spatial data and their attributes.
Biological and Genome Databases: Store biological information such as genetic sequences and related information.
Data Warehouses: Central repositories for integrated data from various sources that support analysis and reporting.
Mobile Databases: Databases designed to be used on mobile devices with mobility-specific characteristics.
Real-time and Active Databases: Process data in real-time, responding to events as they occur.
Impact of Databases and Database Technology
Businesses: Impactful in various sectors such as:
Banking
Insurance
Retail
Transportation
Healthcare
Manufacturing
Service Industries: Significant for:
Financial Services
Real-estate
Legal Services
Electronic Commerce
Small Businesses
Education: Provides resources for content delivery and management.
Recent Developments: Technologies influencing databases include:
Social Networks
Environmental Applications
Scientific Applications
Medicine and Genetics
Personalized Applications: Evolving due to smart mobile devices to provide customized experiences based on users' behavior.
Simplified Database System Environment
Components:
Users/Programmers: Interact with data.
Database: Core storage of data.
Application Programs/Queries: Tools used to communicate with the database.
DBMS Software: Processes queries and manages data access.
Visualization:
Stored Database: Contains the actual data.
Definition (Meta-Data): Data that describes or provides information about other data.
Typical DBMS Functionality
Define Database: Configuration of data types, structures, constraints for the database.
Construct Database: Load and construct the initial database contents in a secondary storage medium.
Manipulate Database:
Retrieval: Conduct queries to extract data, generate reports.
Modification: Insertions, deletions, and updates to database content.
Access Database: Available through web applications for broader access.
Concurrency Handling: DBMS manages simultaneous database access by multiple users or application programs while ensuring data validity and consistency.
Application Activities Against a Database
Interaction with Database: Applications generate requests:
Queries: Access various data parts and formulate specific results.
Transactions: Perform actions such as reading and updating data, or generating new data to store.
Security Measures: Applications must prevent unauthorized access to data.
Adaptability: Applications should keep pace with changing user requirements for effective database interaction.
Additional DBMS Functionality
Security Measures: Protection against unauthorized access and breaches.
Active Processing: The capability to perform data-initiated actions automatically.
Data Presentation: Tools for visualizing and displaying data effectively.
Database Maintenance: Ongoing upkeep of the database and its programs throughout their lifecycle to ensure reliability and performance.
Example of a Database (Conceptual Data Model)
Mini-world: University environment.
Entities within Mini-world:
STUDENTs
COURSEs
SECTIONs of COURSEs
(academic) DEPARTMENTs
INSTRUCTORs
Relationships Among Entities:
SECTIONs are of specific COURSEs.
STUDENTs enroll in SECTIONs.
COURSEs may have prerequisite COURSEs.
INSTRUCTORs teach SECTIONs.
COURSEs are offered by DEPARTMENTs.
STUDENTs major in DEPARTMENTs.
Representation: Typically modeled in a conceptual data model like the ENTITY-RELATIONSHIP model.
Example of a Simple Database
COURSE Table:
Fields: Coursename, Coursenumber, Credit_hours, Department.
Sample Entries:
Intro to Computer Science (CS1310) - 4 credits, CS Department
Data Structures (CS3320) - 4 credits, CS Department
Discrete Mathematics (MATH2410) - 3 credits, MATH Department
SECTION Table:
Fields: Sectionidentifier, Coursenumber, Semester, Year, Instructor.
Sample Entries:
Section 85 (MATH2410) - Fall 2004 - Instructor King.
Section 92 (CS1310) - Fall 2004 - Instructor Anderson.
GRADE REPORT Table:
Fields: Studentnumber, Sectionidentifier, Grade.
Sample Entry: Student 17, Section 112, Grade B.
PREREQUISITE Table:
Links course numbers to their corresponding prerequisite courses.
Main Characteristics of the Database Approach
Self-describing nature:
DBMS Catalog: Stores a description of a database, including data structures and constraints, known as meta-data.
Interoperability: This allows the DBMS to work across different database applications netting flexibility.
Program-Data Independence:
Affordance to change data structures and storage without altering existing DBMS access programs.
Lack of strict meta-data in newer systems: Some NoSQL systems maintain data definition within their structure, being self-describing.
Example of a Simplified Database Catalog
Relation Catalog Example:
Relations:
Relationname: STUDENT, Noof_columns: 4.
Relationname: COURSE, Noof_columns: 4.
Relationname: SECTION, Noof_columns: 5.
Relationname: GRADEREPORT, Noofcolumns: 3.
Relationname: PREREQUISITE, Noof_columns: 2.
Columns:
Specify Columnname, Datatype, and the relation it belongs to. For example:
Column: Name, Datatype: Character (30), Belongsto_relation: STUDENT.
Column: Studentnumber, Datatype: Character (4), Belongstorelation: STUDENT.
Column: Class, Datatype: Integer (1), Belongsto_relation: STUDENT.
Data Abstraction in the Database Approach
Data Model: Utilized to hide lower-level storage details, presenting users with a conceptual framework for understanding the database.
Multiple Views: Each user can have a different view of the database tailored to their specific interest or role.
Sharing of Data and Multi-user Transaction Processing
Multi-user Access: Allows multiple users to retrieve from and update the database concurrently.
Concurrency Control: DBMS ensures all transactions are executed correctly or entirely aborted in case of failure.
Recovery Subsystem: Guarantees that each completed transaction’s effects are permanently recorded in the database.
OLTP (Online Transaction Processing): A crucial aspect of databases, facilitating hundreds of transactions per second.
Database Users
User Classification:
Actors on the Scene: Users who directly interact with and control database content.
Workers Behind the Scene: Users who design, develop, and maintain the underlying DBMS and associated tools.
Database Users (Actors on the Scene)
Database Administrators (DBAs):
Responsibilities include authorizing access, monitoring usage, managing resources, and ensuring efficient database operations.
Database Designers:
Focus on defining database content, structure, constraints, and transactions, aligning with user requirements.
End Users:
Utilize the database for various activities such as queries, reports, and updates; each with different levels of engagement (casual, parametric, sophisticated).
System Analysts & Application Developers:
Analysts design user-centric applications; developers implement and deploy these applications, including business analysts working on large datasets.
Database Users (Workers Behind the Scene)
System Designers and Implementors:
Build DBMS packages in modular formats, test and debug them, ensuring integration with applications and system environments.
Tool Developers:
Create modeling and design tools, performance monitors, prototyping and testing tools that enhance application development and database usage.
Operators and Maintenance Personnel:
Oversee the running and systematic maintenance of database systems and their hardware/software environments.
Recent Developments
Explosion of Social and Web Data:
Social networks generate vast amounts of user-generated content.
Search engines create extensive repositories of web pages to index and serve.
Emergence of New Technologies:
Big Data Systems: Technologies to manage massive data influxes.
NoSQL Databases: Designed for rapid search and retrieval tasks across extensive document collections.
Cloud Computing: Enables a scalable and flexible data hosting environment.
Extending Database Capabilities
Emergence of Big Data Technologies and NoSQL Databases:
Need for new technologies arose to handle large volumes, with data growth reaching petabytes per day (10^15 bytes).
Technologies like Hadoop and MapReduce for distributed data processing emerged from companies like Yahoo and Google, evolving through frameworks like Spark.
NoSQL Systems: Formulate flexible transaction processing models for unstructured data and support seamless interactions in social networks.
Advantages of Using the Database Approach
Reduces Redundancy: Minimizes duplicate data storage and maintenance efforts.
Data Sharing: Allows multiple users access while safeguarding against unauthorized access.
Persistent Storage: Ensures efficient and long-lasting storage of objects and supports effective query processing.
Advanced Features: Query optimization, backup and recovery services enhance database usability.
Complex Relationships: Supports intricate relationships, integrity constraints, and rules/triggers for data maintenance.
Standardization: Helps implement consistent data standards throughout organizations.
Application Development: Eases the addition of incremental changes, reducing overall development time.
Flexibility and Availability: Ensures data is adaptable and continuously accessible.
When Not to Use a DBMS
Cost Inhibitors: Examining the costs associated with implementing and maintaining a DBMS involves certain constraints.
Unnecessary Situations: Cases arise where a simpler solution suffices, negating the need for a DBMS.
Infeasibility: When stringent real-time processing is paramount, or when data exhibits excessive complexity, using a DBMS might not be feasible.
Chapter Summary
Overview of Database Types and Applications.
Essential Database Definitions.
Typical Functionalities of a DBMS.
Illustrative University Database Example.
Characteristics of Database Approaches.
Classification of Database Users.
Advantages attributed to the Database Approach.
Historical Progression in Database Technology.
Innovations Increasing Database Capabilities.
Situations and conditions in which using a DBMS is not ideal.