0% found this document useful (0 votes)
1 views

Chapter 3 Database

This document outlines a course on databases, specifically focusing on Microsoft Access. It covers topics such as database introduction, creating tables, querying data, and using forms, along with practical tasks for hands-on learning. The course aims to provide a comprehensive understanding of database management and data organization techniques.

Uploaded by

goovatech
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
1 views

Chapter 3 Database

This document outlines a course on databases, specifically focusing on Microsoft Access. It covers topics such as database introduction, creating tables, querying data, and using forms, along with practical tasks for hands-on learning. The course aims to provide a comprehensive understanding of database management and data organization techniques.

Uploaded by

goovatech
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 19

COMPUTER PACKAGES COURSE

CHAPTER 3: DATABASE

1 Mr. Chaun
Mr. Chaun Evans
Table of Contents
Topic 1: Introduction to Database............................................................................................................... 3

1. Introduction ......................................................................................................................................... 3

2. Traditional File Organizations ............................................................................................................ 3

3. Data Models ........................................................................................................................................ 4

Topic 2: Getting Started with Access ......................................................................................................... 4

1. Orientation to Microsoft Access ......................................................................................................... 4

2. Create a Simple Access Database ....................................................................................................... 5

3. Get Help and Configure Options ........................................................................................................ 5

Topic 3: Tables ........................................................................................................................................... 6

1. Creating Tables ................................................................................................................................... 6

2. Working with Table Data.................................................................................................................... 6

Tasks: ................................................................................................................................................. 7

3. Validation Rules.................................................................................................................................. 7

Topic 4: Querying a Database..................................................................................................................... 9

1. Create Basic Queries ........................................................................................................................... 9

2. Sort and Filter Data in a Query ......................................................................................................... 10

3. Perform Calculations in a Query....................................................................................................... 10

Topic 5: Designing a Relational Database ................................................................................................ 11

1. Relational Database Design .............................................................................................................. 11

2. Create Tables .................................................................................................................................... 12

3. Create Table Relationships ............................................................................................................... 13

Topic 6: Using Forms ............................................................................................................................... 14

1. Create Basic Access Forms ............................................................................................................... 14

2 Mr. Chaun
2. Work with Data on Access Forms .................................................................................................... 15

Topic 7: Sharing Data Across Applications.............................................................................................. 16

1. Import Data into Access.................................................................................................................... 16

2. Export Data to Text File Formats ..................................................................................................... 17

3. Export Access Data to Excel............................................................................................................. 17

4. Create a Mail Merge ......................................................................................................................... 17

Conclusion ................................................................................................................................................ 19

Topic 1: Introduction to Database


1. Introduction

A database is an organized collection of structured information or data, typically stored electronically in


a computer system. Databases are designed to manage, store, and retrieve data efficiently. They provide
a systematic way to store and access data, which can include text, numbers, images, and other types of
data.

Key Points:

 Definition: A database is a structured set of data held in a computer, especially one that is
accessible in various ways.
 Purpose: To ensure efficient storage, retrieval, and management of data.
 Examples: Hospital databases, school databases, banking databases.

2. Traditional File Organizations

Before the advent of databases, data was often stored in traditional file-based systems. These systems
organize data in separate files, each containing information about a specific entity.

Key Characteristics:

 File-Based Systems: Data is stored in individual files.


 Limitations:
o Redundancy: Data may be duplicated across files.
o Inconsistency: Changes in one file may not be reflected in others.
o Difficult Retrieval: Complex queries are harder to perform.

3
Mr. Chaun
Examples:

 In a traditional file-based system at Kisumu General Hospital, patient records might be stored
in separate files, leading to duplication and inconsistencies.

3. Data Models

Data models define how data is structured and organized in a database. They provide a conceptual
framework for understanding and designing the database structure.

Common Data Models:

 Hierarchical Model:
o Structure: Data is organized in a tree-like structure.
o Characteristics: Data is stored in parent-child relationships.
o Example: The organizational structure of Nairobi City Council where employees are
arranged in a hierarchy.
 Relational Model:
o Structure: Data is organized in tables (relations) with rows and columns.
o Characteristics: Tables can be linked using keys.
o Example: Equity Bank’s customer database where tables might include customer
details, account information, and transaction records.
 Network Model:
o Structure: Data is represented as records and relationships in a network-like structure.
o Characteristics: More flexible than hierarchical models, allowing multiple parent-child
relationships.
o Example: Complex systems where entities are connected in a network, like a supply
chain management system.

Topic 2: Getting Started with Access


1. Orientation to Microsoft Access

Microsoft Access is a powerful database management system that combines the capabilities of a
relational database engine with a user-friendly interface. It allows users to create and manage databases,
design forms for data entry, generate reports, and perform queries to retrieve specific information.

Key Components:

 Ribbon: The toolbar at the top that contains various tools and commands.
 Navigation Pane: The panel on the left that provides access to database objects such as tables,
queries, forms, and reports.
 Tables: The core objects that store data in a structured format with rows and columns.

4
Mr. Chaun
2. Create a Simple Access Database

Creating a database in Microsoft Access involves setting up a new database file and designing tables to
store data.

Steps:

1. Open Microsoft Access and select Blank Database.


2. Enter a Name for your database, such as "Mombasa School Records".
3. Click Create to generate your new database file.
4. Design Tables to store data by defining fields (e.g., StudentID, Name, Age) and specifying data
types (e.g., Text, Number).
5. Save your table and enter sample data.

3. Get Help and Configure Options

Microsoft Access provides various help and configuration options to assist users in managing their
databases effectively.

Help Options:

 Help Tab: Use the Help tab or press F1 to access tutorials and guidance.
 Configuration Options: Go to File > Options to adjust settings such as General, Current
Database, and Object Designers.

Saving and Backup:

 Regularly Save your database to avoid data loss. Use File > Save As to save a backup copy or
export your data.

Tasks:

1. Create a New Database


o Open Microsoft Access.
o Select Blank Database.
o Name your database "Mombasa School Records".
o Click Create to establish the database file.
2. Design and Save a Table
o Create a table within your new database.
o Define fields such as StudentID, Name, and Grade.
o Enter some sample data into the table.
o Save the table with an appropriate name, such as "Student Information".
3. Configure Options and Backup
o Access the Help feature (press F1) to find information on creating reports.
o Go to File > Options and configure settings like AutoSave.

5
Mr. Chaun
o Save your database and create a backup copy using File > Save As.

Topic 3: Tables
1. Creating Tables

In Microsoft Access, tables are essential for storing data. Each table is composed of fields (columns) and
records (rows).

Steps to Create a Table:

1. Open Your Database in Microsoft Access.


2. Go to the Create tab on the Ribbon.
3. Click Table Design to open the design view.
4. Define the Field Names and Data Types:
o Field Names: Examples include StudentID, Name, Age, Grade, Address, and
EnrollmentDate.
o Data Types: Text, Number, Date/Time, Currency, etc.
5. Set a Primary Key for the table (e.g., StudentID) to uniquely identify each record.
6. Save the table with a meaningful name, such as "Student Information".

Example Fields for a Student Table:

 StudentID (AutoNumber) - Unique identifier for each student.


 Name (Text) - Full name of the student.
 Age (Number) - Age of the student.
 Grade (Text) - Grade or class of the student.
 Address (Text) - Home address of the student.
 EnrollmentDate (Date/Time) - Date the student was enrolled.

2. Working with Table Data

After creating a table, you can manage data by entering, editing, and organizing it.

Key Actions:

1. Enter Data: Switch to Datasheet View to enter data directly into the table.
2. Edit Records: Click on any cell to modify existing data.
3. Delete Records: Select the record and use the delete key or right-click and choose delete.
4. Sort and Filter Data: Use sort and filter options to organize and find specific records.
5. Use Queries: Create queries to retrieve specific subsets of data based on criteria.

Example Data Entry for the Student Table:

StudentID Name Age Grade Address EnrollmentDate

6
Mr. Chaun
1 Jane Wanjiku 15 Form 3 123 Kenyatta Ave, Nairobi 2023-01-15
2 John Mwangi 14 Form 2 456 Uhuru Rd, Mombasa 2023-02-20
3 Mary Akinyi 16 Form 4 789 Moi Rd, Kisumu 2023-03-10
4 Peter Otieno 15 Form 3 101 Uhuru St, Nakuru 2023-04-05
5 Grace Njeri 14 Form 2 202 Moi Ave, Eldoret 2023-05-22
6 Samuel Kamau 17 Form 4 303 Kenyatta Rd, Eldoret 2023-06-30

Tasks:

1. Create a Table:
o Open your database in Microsoft Access.
o Go to the Create tab and click Table Design.
o Define the following fields with appropriate data types:
 StudentID (AutoNumber)
 Name (Text)
 Age (Number)
 Grade (Text)
 Address (Text)
 EnrollmentDate (Date/Time)
o Set StudentID as the primary key.
o Save the table with the name "Student Information".
2. Enter and Manage Data:
o Switch to Datasheet View of the "Student Information" table.
o Enter the sample data provided in the table above, including at least 6 records.
o Edit a record by changing one of the student's details.
o Delete a record and verify that it has been removed from the table.
3. Sort and Filter Data:
o Sort the records by Name in alphabetical order.
o Filter the records to show only students in Form 3.
o Take note of the records that appear after applying the filter.
4. Create a Query:
o Go to the Create tab and click Query Design.
o Add the "Student Information" table to the query design view.
o Create a query to retrieve all students who are 15 years old or older.
o Save the query with a name like "Students Age 15 and Older".

3. Validation Rules

Validation rules are essential for maintaining data integrity in a database. They ensure that data entered
into the database adheres to specific criteria and is consistent.

Notes on Validation Rules:

7
Mr. Chaun
 Validation Rule Syntax: Validation rules use expressions to define constraints on data. For
example, >=1 AND <=120 for age ensures that only values between 1 and 120 are accepted.
 Common Validation Rules:
o Text Length: Ensure the length of text data is within a specified range. For instance, a
phone number might need to be exactly 10 characters long.
o Range: Set numeric fields to accept values within a certain range. For example, a salary
field might be restricted to values greater than $0.
o Date Constraints: Ensure dates are valid and within a specific range. For example, a
birthdate must be before the current date.
o Pattern Matching: Use patterns to validate formats. For instance, an email address
might need to follow the pattern *@*.*.
o Custom Validation Text: Provides users with a clear error message when the validation
rule is violated. For example, “Please enter a valid email address.”

Examples of Validation Rules:

 Age Field: >=1 AND <=120 with validation text “Age must be between 1 and 120.”
 Phone Number Field: Like "###-###-####" with validation text “Phone number must be in
the format 123-456-7890.”
 Email Field: Like "*@*.*" with validation text “Enter a valid email address.”

4. Required Fields

Required fields ensure that essential data is not omitted when entering or updating records. This enforces
the completeness of critical information.

Notes on Required Fields:

 Purpose: Ensures critical information is entered before saving a record, preventing incomplete
data.
 Default Value: Can be set to a specific value if no other input is provided. For example, a
default value of “N/A” for a middle name field.
 Error Handling: If a required field is left blank, an error message will prompt the user to
provide the necessary data.

Examples of Required Fields:

 Name Field: Set as required to ensure every student record has a name.
 Address Field: Set as required to ensure every record has an address.

4. Indexed Fields

Indexing improves the speed and efficiency of data retrieval and ensures uniqueness where necessary.
Indexed fields can be set to enforce uniqueness or allow duplicates.

Notes on Indexed Fields:

8
Mr. Chaun
 Purpose: Enhances query performance by allowing quick lookups of data.
 Unique Index: Ensures all values in the indexed field are unique. Useful for fields like ID
numbers.
 Non-Unique Index: Allows duplicate values and is used for fields where uniqueness is not
required.

Examples of Indexed Fields:

 StudentID Field: Set as indexed with No Duplicates to ensure each student has a unique ID.
 CourseCode Field: Set as indexed with Duplicates OK if multiple students can be enrolled in
the same course.

Tasks:

1. Set Validation Rules:


o Open your "Students" table in Design View.
o Select the "Age" field.
o In the Field Properties pane, set the Validation Rule to >=1 AND <=120.
o Enter the Validation Text as “Age must be between 1 and 120.”
o Save the table design.
o Test by entering invalid ages to ensure the validation rule works.
2. Set Required Fields:
o Open your "Students" table in Design View.
o Select the "Name" field.
o Set the Required property to Yes.
o Save the table design.
o Test by trying to save a record without entering a name to ensure the required field
constraint is enforced.
3. Set Indexed Fields:
o Open your "Students" table in Design View.
o Select the "StudentID" field.
o Set the Indexed property to Yes (No Duplicates).
o Save the table design.
o Test by entering duplicate student IDs to ensure that the index prevents duplication.

Topic 4: Querying a Database


1. Create Basic Queries

Queries in Microsoft Access are used to retrieve specific data from one or more tables. Basic queries
allow you to select, filter, and display data based on certain criteria.

Steps to Create a Basic Query:

1. Open Your Database in Microsoft Access.

9
Mr. Chaun
2. Go to the Create tab on the Ribbon.
3. Click Query Design.
4. Add the relevant tables to the query design view.
5. Drag the fields you want to include in the query to the grid below.
6. Specify any criteria or conditions you want to apply (e.g., students in a specific grade).
7. Click Run to view the results.
8. Save the query with a meaningful name.

Example Query:

 Objective: Retrieve all students in Form 3.


 Fields: StudentID, Name, Grade.

2. Sort and Filter Data in a Query

Sorting and filtering allow you to organize and narrow down the data displayed by a query.

Sorting:

 Ascending/Descending Order: Click on the Sort row in the query design view and choose
Ascending or Descending to sort the data based on a specific field (e.g., Name).

Filtering:

 Criteria: Specify criteria in the Criteria row of the query design view to filter records (e.g.,
only students aged 15).

Example Sorting and Filtering:

 Sort By: Name (Ascending).


 Filter By: Students in Form 3.

3. Perform Calculations in a Query

You can use queries to perform calculations on data, such as summing values, calculating averages, or
counting records.

Steps to Perform Calculations:

1. Open Query Design and add the relevant table(s).


2. Drag the fields needed for calculations to the grid.
3. Use aggregate functions like SUM, AVG, COUNT in the Total row.
4. Specify the calculation details in the grid (e.g., calculate the average age of students).
5. Click Run to view the results.
6. Save the query with a descriptive name.

10
Mr. Chaun
Example Calculation:

 Objective: Calculate the average age of students in Form 3.


 Function: AVG(Age).

Tasks:

1. Create a Basic Query:


o Open your database in Microsoft Access.
o Go to the Create tab and click Query Design.
o Add the "Student Information" table to the query design view.
o Drag the fields StudentID, Name, and Grade to the query grid.
o Set the criteria to display only students in Form 3.
o Click Run to view the results.
o Save the query with the name "Form 3 Students".
2. Sort and Filter Data in a Query:
o Open the "Form 3 Students" query.
o Sort the records by Name in ascending order.
o Apply a filter to show only students aged 15.
o Save the sorted and filtered query with the name "Form 3 Students Sorted and
Filtered".
3. Perform Calculations in a Query:
o Go to the Create tab and click Query Design.
o Add the "Student Information" table to the query design view.
o Drag the Age field to the query grid.
o In the Total row, select AVG to calculate the average age.
o Set the criteria to show students in Form 3 if necessary.
o Click Run to view the average age.
o Save the query with the name "Average Age of Form 3 Students".

Topic 5: Designing a Relational Database


1. Relational Database Design

Relational database design involves creating tables and defining relationships between them to ensure
data integrity and minimize redundancy.

Key Concepts:

 Primary Key: A unique identifier for each record in a table.


 Foreign Key: A field in one table that links to the primary key in another table.
 Relationships:
o One-to-One: Each record in one table is related to a single record in another table.
o One-to-Many: A single record in one table can relate to multiple records in another
table.

11
Mr. Chaun
o Many-to-Many: Records in one table can relate to multiple records in another table,
typically using a junction table.

Example Design:

 Tables: Students, Courses, Enrollments


 Relationships:
o Each student can enroll in multiple courses.
o Each course can have multiple students.

2. Create Tables

Table 1: Students

Field Name Data Type Description


StudentID AutoNumber Unique identifier for each student
Name Text Full name of the student
Age Number Age of the student
Address Text Home address of the student

Example Data:

StudentID Name Age Address


1 Jane Wanjiku 15 123 Kenyatta Ave, Nairobi
2 John Mwangi 14 456 Uhuru Rd, Mombasa
3 Mary Akinyi 16 789 Moi Rd, Kisumu
4 Peter Otieno 15 101 Uhuru St, Nakuru
5 Grace Njeri 14 202 Moi Ave, Eldoret

Table 2: Courses

Field Name Data Type Description


CourseID AutoNumber Unique identifier for each course
CourseName Text Name of the course
Description Text Brief description of the course

Example Data:

CourseID CourseName Description


1 Mathematics Basic and advanced mathematics
2 Science General science and experiments
3 English Literature Study of English language and literature
4 History Historical events and analysis
5 Computer Science Introduction to programming and computing

12
Mr. Chaun
Table 3: Enrollments

Field Name Data Type Description


EnrollmentID AutoNumber Unique identifier for each enrollment
StudentID Number Foreign Key linking to Students table
CourseID Number Foreign Key linking to Courses table
EnrollmentDate Date/Time Date when the student enrolled

Example Data:

EnrollmentID StudentID CourseID EnrollmentDate


1 1 1 2024-01-15
2 1 3 2024-01-15
3 2 2 2024-02-20
4 3 1 2024-03-10
5 4 4 2024-04-05
6 5 5 2024-05-22
3. Create Table Relationships

Steps to Create Relationships:

1. Open Your Database in Microsoft Access.


2. Go to the Database Tools tab and click Relationships.
3. Add the following tables to the Relationships view:
o Students
o Courses
o Enrollments
4. Define Relationships:
o Drag the StudentID field from the "Students" table to the StudentID field in the
"Enrollments" table.
o Set the relationship type to One-to-Many and enforce Referential Integrity.
o Drag the CourseID field from the "Courses" table to the CourseID field in the
"Enrollments" table.
o Set the relationship type to One-to-Many and enforce Referential Integrity.
5. Click Create to establish the relationships.
6. Save the relationship layout.

Tasks:

1. Create the Students Table:


o Open Microsoft Access.
o Go to the Create tab and click Table Design.
o Define the following fields:
 StudentID (AutoNumber) - Primary Key

13
Mr. Chaun
Name (Text)
Age (Number)
Address (Text)
o Save the table with the name "Students".
o Enter the provided data.
2. Create the Courses Table:
o Go to the Create tab and click Table Design.
o Define the following fields:
 CourseID (AutoNumber) - Primary Key
 CourseName (Text)
 Description (Text)
o Save the table with the name "Courses".
o Enter the provided data.
3. Create the Enrollments Table:
o Go to the Create tab and click Table Design.
o Define the following fields:
 EnrollmentID (AutoNumber) - Primary Key
 StudentID (Number) - Foreign Key
 CourseID (Number) - Foreign Key
 EnrollmentDate (Date/Time)
o Save the table with the name "Enrollments".
o Enter the provided data.
4. Create Table Relationships:
o Go to the Database Tools tab and click Relationships.
o Add the "Students", "Courses", and "Enrollments" tables.
o Drag the StudentID from "Students" to StudentID in "Enrollments".
o Drag the CourseID from "Courses" to CourseID in "Enrollments".
o Define both relationships as One-to-Many and enforce Referential Integrity.
o Save the relationship layout.

Topic 6: Using Forms

Forms in Microsoft Access are user-friendly interfaces for entering, displaying, and editing data. They
help users interact with the database in a structured manner.

1. Create Basic Access Forms

Overview: Creating forms in Access allows you to design custom interfaces for data entry and display.
Forms can simplify user interaction with the database, making data management more efficient.

Steps to Create a Basic Access Form:

1. Open Your Database: Start Microsoft Access and open your existing database.
2. Go to the Forms Section:
o In the Navigation Pane, click on the "Forms" category.

14
Mr. Chaun
oClick on "Create" on the Ribbon.
3. Choose a Form Type:
o Form Wizard: Guides you through a step-by-step process to create a form based on your
table or query.
o Blank Form: Allows you to start from scratch and manually design your form.
4. Design the Form:
o Use the Form Design Tools to add controls like text boxes, combo boxes, and buttons.
o Arrange and format these controls to suit your data entry needs.
5. Save the Form:
o Give your form a descriptive name (e.g., "Student Entry Form").
o Click "Save" on the Quick Access Toolbar.

Example: Create a form named "Student Entry Form" to allow data entry for the "Students" table,
including fields like StudentID, Name, Age, and Course.

2. Work with Data on Access Forms

Overview: Working with data on forms involves entering, editing, and navigating through records.
Forms provide a controlled environment to interact with your data without directly modifying the
underlying tables.

Steps to Work with Data on Access Forms:

1. Open the Form:


o Double-click on the form in the Navigation Pane to open it in Form View.
2. Enter Data:
o Click on each field in the form and enter the required information.
o Use the tab key to move between fields.
3. Edit Existing Records:
o Use the navigation buttons (e.g., Next, Previous) to locate the record you want to edit.
o Modify the data as needed in the form fields.
4. Save Records:
o Click on the "Save" button or use the shortcut Ctrl+S to save any changes made to the
record.
5. Delete Records:
o Select the record you wish to delete.
o Click on the "Delete" button on the Ribbon or use the shortcut Ctrl+Minus.

Example: Using the "Student Entry Form", enter a new student record with the following details:

 StudentID: 001
 Name: Jane Mwangi
 Age: 21
 Course: Computer Science

Then, edit an existing record for a student named "John Otieno" by updating the age from 22 to 23.

15
Mr. Chaun
Tasks:

1. Create a Basic Access Form:


o Open your database and navigate to the "Forms" section.
o Select "Create" and choose "Form Wizard".
o Follow the prompts to create a form based on the "Students" table.
o Design the form to include fields like StudentID, Name, Age, and Course.
o Save the form as "Student Entry Form".
2. Enter and Edit Data on the Form:
o Open the "Student Entry Form" in Form View.
o Enter a new record with the following details:
 StudentID: 002
 Name: Samuel Achieng
 Age: 23
 Course: Business Analytics
o Navigate to an existing record and edit the data as follows:
 Change the age of John Otieno from 22 to 23.
o Save the changes by clicking "Save" or using Ctrl+S.
3. Delete a Record:
o Open the form and locate the record for "Mary Nyambura".
o Delete this record by selecting it and clicking the "Delete" button.
o Confirm the deletion if prompted.

Topic 7: Sharing Data Across Applications


1. Import Data into Access

Importing data into Microsoft Access allows you to bring data from other sources into your database.
This can be useful for consolidating data from spreadsheets, text files, or other databases.

Steps to Import Data:

1. Open Your Database in Microsoft Access.


2. Go to the External Data tab on the Ribbon.
3. Select the data source you want to import from (e.g., Excel, Text File).
4. Follow the import wizard to locate the file and specify import options.
5. Choose the destination table or create a new table.
6. Review the imported data and adjust field settings if necessary.
7. Click Finish to complete the import process.

Example:

 Import data from an Excel file with student information into the "Students" table in Access.

16
Mr. Chaun
2. Export Data to Text File Formats

Exporting data to text file formats (e.g., CSV or TXT) allows you to share data with other applications
or systems that support these formats.

Steps to Export Data:

1. Open Your Database in Microsoft Access.


2. Go to the External Data tab on the Ribbon.
3. Click on Text File under the Export group.
4. Select the table or query you want to export.
5. Follow the export wizard to specify file location and format options (e.g., CSV).
6. Choose the delimiter (e.g., comma for CSV) and other settings.
7. Click OK to complete the export process.

Example:

 Export the "Students" table data to a CSV file for sharing with another department.

3. Export Access Data to Excel

Exporting data from Access to Excel is useful for further data analysis, creating reports, or sharing data
in a familiar format.

Steps to Export Data to Excel:

1. Open Your Database in Microsoft Access.


2. Go to the External Data tab on the Ribbon.
3. Click on Excel under the Export group.
4. Select the table or query you want to export.
5. Specify the file location and format options (e.g., Excel Workbook).
6. Click OK to complete the export process.
7. Open the exported Excel file to review the data.

Example:

 Export the "Courses" table to an Excel file to create a detailed report.

4. Create a Mail Merge

Mail merge allows you to create personalized documents, such as letters or labels, using data from
Access.

Steps to Create a Mail Merge:

17
Mr. Chaun
1. Open Microsoft Word and go to the Mailings tab on the Ribbon.
2. Click Start Mail Merge and choose the type of document (e.g., Letters).
3. Click Select Recipients and choose Use an Existing List.
4. Browse to your Access database and select the table or query containing the recipient data.
5. Insert merge fields (e.g., Name, Address) into your document.
6. Click Finish & Merge to generate the final documents.
7. Review and print or save the merged documents.

Example:

 Create a set of personalized letters to students using data from the "Students" table.

Tasks:

1. Import Data into Access:


o Open your database in Microsoft Access.
o Go to the External Data tab and select Excel.
o Choose an Excel file containing student information with columns for StudentID, Name,
Age, and Address.
o Follow the import wizard to import the data into the "Students" table.
o Review and adjust field settings if necessary, then click Finish.
2. Export Data to Text File Formats:
o Open your database in Microsoft Access.
o Go to the External Data tab and click on Text File.
o Select the "Students" table.
o Follow the export wizard to save the data as a CSV file.
o Choose the delimiter (comma) and complete the export process.
3. Export Access Data to Excel:
o Open your database in Microsoft Access.
o Go to the External Data tab and click on Excel.
o Select the "Courses" table.
o Specify the file location and format (Excel Workbook).
o Click OK to complete the export process.
o Open the Excel file to review the exported data.
4. Create a Mail Merge:
o Open Microsoft Word.
o Go to the Mailings tab and click Start Mail Merge, selecting Letters.
o Click Select Recipients and choose Use an Existing List.
o Browse to your Access database and select the "Students" table.
o Insert merge fields such as Name and Address into your letter.
o Click Finish & Merge to generate the personalized letters.
o Review and print or save the merged documents.

18
Mr. Chaun
Conclusion

This course provided a comprehensive overview of essential Microsoft Access functionalities. Starting
with foundational concepts of databases, we moved through practical applications including creating and
managing tables, querying data, designing relational databases, and working with forms. We explored
validation rules, required fields, and indexed fields to ensure data integrity and optimize performance.
Additionally, we covered techniques for sharing data across applications and leveraging forms for
efficient data entry and management.

By mastering these skills, you are now equipped to effectively design, manage, and utilize databases in
Microsoft Access, enhancing your ability to handle and analyze data in a structured and user-friendly
environment.

19
Mr. Chaun

You might also like