0% found this document useful (0 votes)
33 views21 pages

3 Database

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
33 views21 pages

3 Database

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 21

Application of Information and

Communication Technology
Hamza Arif
[email protected]
Database
• Data: Data refers to raw, unorganized facts and figures that
are collected and stored. It consists of individual pieces of
information that, on their own, may not provide much
context or meaning.
• Information:
• Information is data that has been processed, organized, or
interpreted to provide context, relevance, and meaning. It
results from the analysis and interpretation of data,
transforming it into something that is useful and
meaningful for decision-making or understanding.
Database
• A database is a structured collection of data that is
organized in a way that makes it easy to manage,
retrieve, and update. Databases are used in various
applications and systems to store and organize
information efficiently. They serve as a central
repository for data, allowing users and applications
to interact with the stored information in a
systematic and controlled manner.
Key Components of a Database:

• Tables:
▫ Definition: Tables are the fundamental structure in a relational
database. They consist of rows and columns, where each row
represents a record, and each column represents an attribute or field.
• Rows (Records):
▫ Definition: Rows, also known as records or tuples, represent individual
entries or instances in a table. Each row contains values for each
column, representing a specific data record.
• Columns (Fields):
▫ Definition: Columns, also known as fields or attributes, represent the
different types of information that can be stored in a table. Each
column has a specific data type.
Hierarchy of Data in database
• Bit:
▫ Definition: The smallest unit of data in computing, representing a
binary value (0 or 1).
▫ Example: 0 or 1.
• Byte:
▫ Definition: A group of 8 bits, representing a basic unit of storage
capable of representing a single character or numerical value.
▫ Example: 01011011
• Field:
▫ Definition: A field is a specific attribute or property in a database table
that stores data of a particular type.
▫ Example: In a "Customer" table, fields could include "CustomerID,"
"FirstName," "LastName," and "Email."
Hierarchy of Data in database
• Record (Row or Tuple):
▫ Definition: A record is a complete set of related fields that represents a single
entity in a database table.
▫ Example: A record in a "Customer" table might include values for
"CustomerID," "FirstName," "LastName," and "Email."
• Table (Relation):
▫ Definition: A table is a collection of records with a consistent set of fields. Each
table in a database represents a specific entity or concept.
▫ Example: A "Customer" table containing multiple records.
• Database:
▫ Definition: A database is a collection of related tables that are organized and
structured to efficiently store, retrieve, and manage data.
▫ Example: A database might include tables for "Customers," "Orders," and
"Products," each related to a specific aspect of a business.
File Maintenance Procedures
• Adding (Inserting) Records: To add a new record to a table, you
use the INSERT INTO statement.

• Modifying (Updating) Records: To modify existing records in a


table, you use the UPDATE statement.

• Deleting Records: To delete records from a table, you use the


DELETE FROM statement.

• Searching (Selecting) Records: To search and retrieve records


from a table, you use the SELECT statement.
Data integrity and validation
• Data integrity and validation are crucial aspects of
database management that ensure the accuracy,
consistency, and reliability of the data stored in a
database. They involve enforcing rules and
constraints to prevent errors, inconsistencies, and
unauthorized access.
• Data Type : Ensures that data entered into a field
matches the specified data type (e.g., string, integer,
date).
• Length Validation :- Checks the length of data entered into
a field against a predefined maximum or minimum length.
• Range Validation: Verifies that numerical data falls within a
specified range.
• Format Validation: Validates data against a specific format
(e.g., email address format, phone number format).
• Presence or Required Field Validation :- Ensures that data
is entered in mandatory fields, preventing the submission
of records with missing essential information.
Forms and report generators
• Forms are user interfaces that allow users to input, view, and
modify data in a database. They provide a structured way for users
to interact with the database without directly using SQL commands.
• Key Features:
• Data Entry: Forms provide a user-friendly interface for entering
data into the database.
• Data Modification: Users can edit and update existing records
through forms.
• Validation: Forms can include validation rules to ensure the
accuracy and completeness of data input.
Report generators
• Report generators are tools or systems that allow users to create formatted
reports based on data stored in the database. These reports present data in a
structured and organized manner for analysis and decision-making.
• Key Features:
• Data Extraction: Report generators extract data from the database to
generate reports.
• Formatting: Users can define the layout, format, and structure of the reports.
• Aggregation: Reports can include aggregated data, summaries, and
calculations.
• Customization: Users can customize reports based on their specific
requirements.
• Export Options: Generated reports can often be exported to different formats
(e.g., PDF, Excel).
Data Security
• Data security in a database is crucial for safeguarding sensitive information,
ensuring privacy, and preventing unauthorized access, modification, or disclosure
of data. Establishing robust data security measures involves a combination of
technologies, policies, and best practices.
• Authentication:
▫ Secure Passwords: Enforce strong password policies, including password
complexity and regular updates.
▫ Multi-Factor Authentication (MFA): Implement MFA to add an extra layer of
security by requiring multiple forms of verification.
• Authorization:
▫ Role-Based Access Control (RBAC): Assign roles to users with specific
permissions, limiting access based on their responsibilities.
▫ Least Privilege Principle: Grant users the minimum level of access needed to
perform their tasks.
Database Backup
• A database backup is a copy of a database that is
created to safeguard against data loss, corruption, or
system failures. The primary purpose of database
backups is to provide a means of restoring the
database to a consistent and known state in the
event of data loss or a critical failure.
Reasons for Database Backups:
• Data Protection:
▫ Protects against accidental deletion, corruption, or loss of data.
• System Failures:
▫ Enables recovery in the event of hardware failures, software crashes, or
other system issues.
• Human Errors:
▫ Provides a safety net in case of mistakes made by users, administrators, or
developers that result in data loss or corruption.
• Security Incidents:
▫ Helps recover data in the aftermath of security incidents, such as data
breaches attacks.
• Compliance Requirements:
▫ Meets regulatory and compliance requirements that mandate data
protection and recovery measures.
Types of Database
• Relational Databases: A relational database is a type of
database management system (DBMS) that organizes
data into tables with rows and columns. The
relationships between the tables are established using
keys, such as primary keys and foreign keys.
• Table Structure:
▫ Data is organized into tables, where each table
represents an entity (e.g., customers, orders) with
rows representing individual records and columns
representing attributes.

Object-Oriented Databases
(OODBMS):
• An object-oriented database management system
(OODBMS) is a type of database that extends the
object-oriented programming paradigm to database
management. In an OODBMS, data is represented as
objects, which encapsulate data and behavior.
• Object Structure:
• Data is represented as objects, which can
encapsulate attributes (data) and methods
(functions).
Multidimensional database
• A multidimensional database (MDB) is a type of
database that is optimized for data storage and
retrieval in a multidimensional format. Unlike
relational databases that use tables to represent
data, multidimensional databases organize data into
cubes& hierarchy. Multidimensional databases are
commonly used in data warehousing and business
intelligence applications where complex analyses
and reporting are required.
Web Database
• A web database is a type of database that is
designed to be used in web applications,
supporting data storage, retrieval, and
management for web-based systems. Web
databases play a crucial role in powering
dynamic and interactive web applications by
storing and organizing data that can be accessed
and manipulated over the internet.
Web Database
• Structured Data Storage: Web databases store
structured data in a way that facilitates efficient
retrieval and manipulation. Common structures
include tables (for relational databases) or documents
(for NoSQL databases).
• Accessibility: Web databases are accessible over the
internet, allowing users to interact with data through
web browsers. This accessibility is fundamental for
web applications that need to provide data-driven
features.
Database Administrator (DBA)
• A Database Administrator (DBA) is a professional
responsible for managing, maintaining, and
optimizing databases within an organization. The
role of a database administrator is critical in ensuring
the integrity, security, and performance of a
database system.
Responsibilities:
• Database Design:
▫ Collaborate with application developers to design efficient and scalable database
structures.
▫ Create and optimize database schemas, ensuring they meet the requirements of the
applications.
• Installation and Configuration:
▫ Install and configure database management systems (DBMS) on servers.
▫ Set up and configure database parameters to optimize performance.
• Security Management:
▫ Implement security measures to safeguard databases from unauthorized access.
▫ Manage user access and permissions, ensuring the principle of least privilege.
• Backup and Recovery:
▫ Develop and implement backup and recovery strategies to ensure data availability
and integrity.
▫ Test and validate backup and recovery processes regularly.

You might also like