Databases F3
Databases F3
Database; refers to a collection of related data that is organized for ease of access, update and retrieval.
It is implemented by using special programs called Database Management System.
Examples of Database Management System are Ms. Access, SQL Server, Oracle, SQLite, Redis,
MongoDB, PostgreSQL and MySQL.
a) Tables
Table is a database structure used to hold related records. It is made up of rows (records) and
columns (fields).
b) Queries
Query is a statement or question used to request for information from the database. Query
statements are written using a special database language called Structured Query language
(SQL).
c) Forms
Form is a graphical interface which is used for entering and viewing data from a table or a query.
It is used for entering, modifying, and viewing records.
d) Reports;
Report is a database object used to view, format, and summarize information from database. It
is the object used to specify what to be printed from the database.
e) Macros;
Macro is a database object used to automate the frequently performed procedure or task in a
database. Suppose that you want to open a report directly from one of your data entry forms.
Add a button to your form and then create a macro that opens the report.
f) Module (programming module)
Module is a built in programming environment used to automate database operations. Example
in Ms. Access there is Visual Basic for Application (VBA)
DATABASE SYSTEMS
Refers to the organization of components that define and regulate collection, storage, management and
use of data in a database.
i) Manual database
Refers to the creation and manipulation of files on physical entities such as books, ledgers,
card files, folders and cabinets.
i) Data: are the raw facts and figures to be processed in the computer. This is what to be
stored and shared among users
ii) Hardware: refers to the physical part of the computer. This involves all kinds of computer
depending on the size of the organization, processor, speed, memory and storage devices.
iii) Software: is the basic interface between the physical database and the user. It comprises of
operating system and application programs such as DBMS.
iv) Users: are the people that interact with the database in any way. Example programmers,
end users, database administrators etc.
Importance of Database systems
Data Integrity and Consistency: DBMS provides mechanisms to ensure data integrity and
consistency by enforcing constraints and rules on the data. This ensures that data is accurate,
complete, and consistent across the system.
Data Security: DBMS provides features such as access control, encryption, and auditing to
ensure that data is secure and protected from unauthorized access or modification.
Efficient Data Retrieval and Management: DBMS provides efficient ways to retrieve and
manage data, using indexes, queries, and other mechanisms. This allows for faster processing of
data and improved performance.
Supports simultaneous access: DBMS allows multiple users to access the data simultaneously,
with transactions ensuring that data is not lost or corrupted due to concurrent access.
Scalability and Flexibility: DBMS allows for the easy addition of new data and the modification
of existing data, making it flexible and scalable. It also allows for the management of large
amounts of data and the ability to handle complex queries and operations.
Reduced Data Redundancy: DBMS reduces data redundancy by storing data in a centralized
location, reducing the need for duplicate data storage and improving data consistency.
Improved Decision Making: DBMS provides the ability to analyze and report on data, allowing
for better decision-making by providing timely and accurate information.
Data Sharing: It allows data to be easily shared among authorized users
Supports data validation: It provides the feature of specifying a certain kind of data to be
entered and stored.
DATABASE DESIGN
Database design is the process of creating a detailed data model for a database, which involves
identifying the data entities, attributes, relationships, and constraints MS access.
Identify the purpose of the database: Including its intended users, the type of data that will be
stored, and the operations that will be performed on the data.
Find and organize required information: It involves gathering of all information to be used in
your database.
Determine the data entities: Identify the entities that will be used to store data. These can be
people, places, objects, or events that will be described in the database.
Identify the attributes of each entity: Determine the specific characteristics of each entity, such
as name, address, phone number, or date of birth.
Define primary keys and foreign keys: Define primary keys for each table to ensure that each
record can be uniquely identified.
Determine the relationships: These can be one-to-one, one-to-many, or many-to-many
relationships. Add foreign keys to entities or create new entity to establish relationship.
Refine your design: by testing your database and analyzing errors that may arise.
Data organization in a database
A database organizes data into:
Field: A character or string of character that represent a data item. It is also called column
Record: A collection of related field that represent a single entity. It is also called row
Table or file: This is the collection of related records. It is made up of fields and records