ictlsm database module

28
 ____ _ Self Access Learning Module MICROSOFT ACCESS 2003 INTRODUCTION TO MICROSOFT ACCESS 2003 Curriculum Development Centre Ministry of Education

Upload: noorrifah-jemanih

Post on 05-Apr-2018

225 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 1/28

 ____________________________________________________________ 

Self Access Learning ModuleMICROSOFT ACCESS 2003

INTRODUCTION TO MICROSOFT ACCESS 2003

Curriculum Development Centre

Ministry of Education

Page 2: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 2/28

 ____________________________________________________________ 

Name of Module: Introduction to Microsoft Access 2003

Learning Outcomes:  At the end of the lesson students should be able to:

1. state the usage of application2. list example which application of database is used3. state the function of the features in database

4. create a new database

Knowledge and Skills:

(a) Students known the meaning and usage of database(b) Start Microsoft Access 2003(c) Create, Name and Save database file

(d) Open existing database(e) Exit database application

Module Summary:

 At the end of the module, students should be able to open, name, save file and closedatabase.

Activity Summary:

 Activities in this module involved:

1. Starting Microsoft Access 20032. Naming and saving file database3. Opening existing database4. Exercises

Meaning of database

A database is the computer equivalent of anorganized list of information. Typically, this information has acommon subject or purpose, such as the list of employees,

phonebook guide or a classmates address book.

Microsoft Access 2003 (Access 2003) is a database systemmanagement (database programs). It can store, manage, manipulate,

analyze, retrieve, display or publish information from database.

Page 3: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 3/28

 ___________________________________________________________ _ 

Activity 1: Starting Microsoft Access 2003

There are two methods to start / launch your Mircosoft Access 2003.

Method 1:

1. Double click on the Mircrosoft Office Access 2003 shortcut on the Windowsdesktop (see below).

Method 2:

1. Click-on the Start button, then click-on Programs, then click-on Microsoft Access

2003 (Figure 1)

1. Thefollowing Access 2003 Getting Started TaskPane will appear on the right side of your 

 Access 2003 screen. (refer figure 2)

2. In the Open area of the Access 2003 GettingStarted Task Pane, click the left mouse

button on Create a new file.

Activity 2: To Name and Save Database File

Figure 1

Shortcut icon MS Access 2003

Figure 2

Page 4: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 4/28

 ______________________________________________________ 

1. The New File menu screen on the top will appear when you click theleft mouse button on Create a new file.

2. Click–on Blank database. (Figure 3)

 A File New Database menu screen, similar to the one below, will be onyour screen. We’ll have to do several “things” to set-up this screen tosave your database. ( Figure 4 )

3. Click-on the small down arrow on the right. Choose My Documents to saveby double clicking on the folder. Your selection should now appear in theSave in : area. (Step 1)

4. Next click-in the area to the right of File Name. Type-in the word studentsprofile as shown at the bottom of the above image. (Step 2)

5. Now click-on the Create button. (Step 3)

2/30

Figure 4

Figure 3

Step 1

Step 2 Step 3

Click here

Page 5: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 5/28

 ______________________________________________________ 

The following Students Profile: Database menu screen will appear.( Figure 5 )

 6. Click File and click Exit to end this session and to close Ms Access 2003.

Activity 3: Open Existing Access Database

There are two methods to open existing database.

Method 1:

1. Repeat Activity 1 to open Ms Access 2003. Once you have created adatabase, you will see your database in the Open portion of the TaskPane.

2. Click students profile. (refer Figure 6)

3/30

Figure 5

Click studentsprofile

Page 6: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 6/28

 ______________________________________________________ 

Method 2:

1. Click File in the Menu Bar, then click Open. (refer figure 7)

2. When the Open menu screen appears, click the small down arrow tothe right of the Look in area and select My Documents.

4/30

Figure 6

Figure 7

Select My Documents

Click students profile

Page 7: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 7/28

 ______________________________________________________ 

3. Then click the name of your database (e.g. students profile.mdb) andthen click Open.

Note:You will notice in the Students Profile: Database menu screen, in the leftborder consist of objects bar: Tables, Queries, Forms, Report, Pages,Macros and Modules.

There are 4 important objects as stated in the table below. 

Objects Bar Function

Table

 A collection of records that identify a category of data, suchas Customers, Orders, or Inventory. Data inside a table isarrange by column name field and row named Record.

Field – A single characteristic or attribute of a person,place, object, event, or idea.

Record – A set of related field values.

Form Use to enter new information, to edit or remove existinginformation or to locate information.

5/30

Access windowtitle bar 

Database windowmenu bar 

Database windowtitle bar 

Objects bar 

Groups bar 

Database toolbar 

Database window

Database windowtoolbar bar 

Page 8: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 8/28

 ______________________________________________________ 

Query

Used to locate information, to view, change or analyze it invarious ways. A select query retrieves data from one or 

more tables and displays the result in datasheet. A selectquery can be used to group record and calculate sums,counts, averages and other types of totals.

ReportTypically used to summarize, organize and analyzeinformation in order to express a particular point of view tospecific audience.

4. Click File and Exit to stop this session.

 At the end of this activities, you had learned how to:

(i) Create a database(ii) Close a database(iii) Open an existing database

In the next module you will learn how to design table and insert data.

Exercises

Question 1

Give two examples of database that you know.

Question 2

Create a database named Teachers Profile. Save this file in My Document directory.

6/30

Page 9: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 9/28

 ______________________________________________________ 

Self Access Learning ModuleMICROSOFT ACCESS 2003

MODULE 2

STUDENTS PROFILE

Curriculum Development Center Ministry Of Education Malaysia

7/30

Page 10: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 10/28

 ______________________________________________________ 

8/30

Page 11: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 11/28

 ______________________________________________________ 

Name of Module: Students Profile

Learning Outcomes: At the end of the lesson, student should be able to

create a table, define primary key and insert data.

Knowledge and Skills

1. Students known how to differentiate field , record and table2. Students known all types of data3. Creating table.4. Define primary key5. Inserting the data in the table.

Module summary:

 At the end of this module, table below will be created by students.

Activities summary:

This module involved a few activities such as;

1. Creating tables2. Inserting the data in the table.3. Exercise

9/30

Page 12: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 12/28

 ______________________________________________________ 

Activity 1: Creating Table

Next you will be creating the fields that make up a database. This is similar to

creating a blank personnel form (on paper) that will be "filled-in" for eachemployee (Name, Address, Phone Number, etc – are called fields in adatabase). This "forms" are called records in a database. There will be arecord, or form, for each employee. All the forms, together, make up a Table(database).

For example, students profiles table as shown below. (Figure 1)

The table above content four records. Each records have four fields which arenumbers field, students name, address and ic number. At the end of thismodule, students will creating a database which is consist a table name“students profile”.

Students profile 3/30

Field 3(address)

Field 1(numbers)

record 2

Field 2(name)

Field 4

(icno)

Figure 1

Page 13: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 13/28

 ______________________________________________________ 

Steps Creating Table

1. Open MS Access 2003 software (Refer module 1, if needed).

2. Click File, click Open, find students profiles database file then click Openbutton. (refer Figure 2)

 3. Database window students profile: Database will appeared as shown below

(Figure 3) then click New button at database windows toolbar. The dialog box inFigure 4 will appear.

3/30

Figure 2

Figure 3

Page 14: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 14/28

 ______________________________________________________ 

4. Click Design View , then click OK to get Datasheet view as shown at Figure 5.

Figure 5

5.  At Field Name column, type in numbers and at Data type column, change valueText  to Number . (refer Figure 6)

4/30

Click this button to view the list of data type, then click number 

Figure 4

DesignView

Fi ure 6

Page 15: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 15/28

 ______________________________________________________ 

There are 10 types of data as stated in the table below;

Types Data Function

Text

You may type in any alphabetical/numerical data that youdesire-up to a maximum of 255 characters. As indicated,this is a text field, so you can't do mathematicalcalculations. Examples of Text data are: names,addresses, stock numbers, room numbers, zip codes, etc

MemoThis field is for lots of text. You can have up to 32,000characters.

Number 

This field is for numbers where you want to add, subtract,multiply, divide, average, and do numerical calculations.

This field can be a very large size, so when we get toField Properties, we'll talk about "sizing" this field so itdoesn't take up too much "space" in storage.

Date/TimeDates and Times. You may format this later, as you maydesire.

CurrencyDollar ($). You may format this later, as you may desire.For example Ringgit Malaysia (RM)

AutoNumber This field is an "automatic" counter that assigns a number each time you put data into a new field.

 Yes/No This is a "True/False" or "Yes/No, 0/1” type of field. 

OLE ObjectThis means "Object Link Embedding" which indicates youcan insert a graphic, picture, sound, etc. Pretty neat to puta photograph in a personnel record or a picture of aninventory item in the stock record (advanced stuff).

Hyperlink A hyperlink is a pointer from one object to another. Thedestination is frequently another Web page, but it can alsobe a picture, an e-mail address, a file (such as amultimedia file or Microsoft Office document), or aprogram. The hyperlink itself can be displayed as text or as a picture.

Lookup WizardThis wizard creates a lookup column, which displays a listof values you can choose from.

5/30

Page 16: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 16/28

 ______________________________________________________ 

7. Insert data in the Field Name, Data Types for each fields as displays (Figure7). Students can move to the next column by press “Tab key”.

Note: Place the cursor at the address inside the Field Name, then change Field Size value from 50 to 100.

8. Click numbers at field name column, click at Edit menu bar , then click

Primary Key or icon Primary Key  . Shown at figure 8.

6/30

Figure 7

PRIMARY KEY means the value in the primary key fields is

need to uniquely identify each record; that’s no record canhave the same value in this field.

Primary key icon

close icon

Figure 8

Figure 9

2. Change Field Sizevalue to 100

1. Place the cursor ataddress

Page 17: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 17/28

 ______________________________________________________ 

9. Click Close icon as shown at figure 7 to close the creating table session.Then dialog box in figure 10 displayed.

10. Click Yes. Dialog box Save As in figure 10 displayed.

 

11. Type students profile at Table Name and then click OK at dialog box as shownin figure 10. Now you had finished creating one table named “studentsprofile:database” as shown below. (Figure 11)

7/30

students profiletable created

Figure 10

Figure 11

Key in table name here

Page 18: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 18/28

 ______________________________________________________ 

Activity 2: Inserting data in the table

The students profile table that created before, not contains any data. Steps belowcan be used to key in the data.

1. Click at Students Profile table then click open at database windowtoolbar. (Figure 13)

2. Datasheet view Students Profile : Table as shown in figure 14 displayed.

8/30

Figure 12

Figure 13

Page 19: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 19/28

 ______________________________________________________ 

3. Key in data at the students profile datasheet.

 At the first row, type number ‘1’ at numbers column. Then, Type name AbdulRahman b. Idris at name column. Next, type address and ic number at addressand icno column.

4. Insert all data in the table by repeating the same process above. As a

result, students will get the table below.

9/30

Figure 15

Figure 14

Page 20: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 20/28

 ______________________________________________________ 

5. Click icon save to saving file. Students Profile table now contained fiverecords.

6. Click icon close to close the inserting data session. 

7. Exit the Microsoft Access 2003 Software.

Exercises

1. Build one of your friends profile table. Named the table “Co-curriculum Data”.That table must have fields as stated below:

 

• Numbers

• Student Name

Class• Club

• Sports

• Uniforms Unit

2. Insert 10 record in that table.

--- FINISH ---

10/30

Figure 16

Page 21: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 21/28

 ______________________________________________________ 

Self Access Learning ModuleMICROSOFT ACCESS 2003

MODULE 3

USING RECORD IN DATABASE

Curriculum Development Center Ministry Of Education Malaysia

Name of Module: Using Record In Database 

11/30

Page 22: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 22/28

 ______________________________________________________ 

Learning Outcomes: At the end of the lesson students should be able to useand manipulate records in database.

Knowledge and Skills:

1. Students should be able to use record in database.2. add records3. add field4. edit records5. find records from Table

Module Summary:

 At the end of this module, table below will be created by students.

Activity Summary:

 Activities in this module involve:

1. add records2. add field3. edit records4. find records from Table

12/30

Page 23: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 23/28

 ______________________________________________________ 

Activity 1: Add Records

1. Open Microsoft Access 2003

1. Click Open an Existing Database, then click file students profile and click OK.

2. In the database window, double click students profile in the Tables pane toopen the table in Datasheet view, as shown in figure 1.

3. To add new record, click on icon New Record that can be seen atdatabase toolbar or at the bottom of datasheet window. (refer figure 1).

4. Add five more record as below. (refer table 1)

name address icno

 Alias b Mohamad No. 5, Jalan Desa Kayang 3, Desa kayang, 01000 950918-02-5533Mohd Shahid b Mohd No. 39, Taman Tapah, Jalan Pahang 35000 Tapah, 950912-05-5321Noorul-Aini bt Ambak No 15, Jalan Limau Kasturi, 4/4A 40000 Shah Alam, 950212-11-5678Noor Asiah bt Zakaria Lot 2646, Kg Simpang Tiga, Bt 6 3/4, 53100 950402-04-5566Fasitah bt. Mansor No. 36, Jln. Melati, Tmn. Mewah, 31000 Batu Gajah, 950606-03-5432

5. Save record.

6. Close students profile : Table.

13/30

Table 1

Figure 1

 

Icon New 

Page 24: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 24/28

 ______________________________________________________ 

Activity 2: Add Fields.

Method 1: Add field after the last field.

1. Click Design button at database toolbar windows Students Profile: Database,to display all the fields.

2. Click field below icno (refer Figure 2)

3. Type in email inside the Field Name and select text as the Data Type.

4. Save the record.

Method 2: Add new field in between the two fields

1. Click Design button at database toolbar windows Students Profile: Database,to display all the fields.

2. Click the address field ( the row will be highlight -refer Figure 3 )

3. Click Insert at menu bar, then click rows. A new row will be added.(refer Figure 4)

  14/30

Figure 3

Figure 4

Figure 2

Page 25: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 25/28

 ______________________________________________________ 

4. Put cursor in between field name and field address. 

5. Type in sex inside the blank Field Name and select text as the Data Type.

(refer Figure 5)

6. Save students profile.

7. Click to close students profile : Table.

Activity 3: Edit Record.

1. Open Students Profile table.

2. To edit record, click inside the selected field. (sex and email)

3. Insert in all the record for sex field and email field. (refer Table 2)

numbers name sex a email

1 Abdul Rahman b. Idris male [email protected] Johana bt. Muhammad female [email protected] Faridah bt Abdullah Female [email protected] Rosnani bt. Sembok Female [email protected] Hassan b. Wahid Male [email protected] Alias b Mohamad Male [email protected]

7 Mohd Shahid b Mohd Male [email protected] Noorul-Aini bt Ambak Female [email protected]

15/30

Figure 5

Page 26: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 26/28

 ______________________________________________________ 

9 Noor Asiah bt Zakaria Female [email protected] Fasitah bt. Mansor female [email protected]

 

4. Repeat step 2 above to add in 5 postcodes (see bold figure) inside the first fiverecord. (Refer Table 3).

Numbers name sex address

1 Abdul Rahman b. male 2304, Rumah Rumah Tasek Gelugor, 13300

2 Johana bt. femal No 24, Jln 1, Taman Seri Sinar, 50600 Kulal3 Faridah bt Abdullah Femal No 39, Jln Pinang Merah 11, 81000 Bandar 4 Rosnani bt. Sembok Femal No 1005, Bukit Datu, 21200 Kuala5 Hassan b. Wahid Male No 101, Taman Rapat Jaya, 41000 Kelang,

5. Save students profile table.

16/30

Table 2

Table 3

Page 27: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 27/28

 ______________________________________________________ 

Activity 4: Finding Record From Table

1. Click field name.

2. Click icon Find (refer Figure 6) and dialog box Find and Replace will bedisplay as below (Figure 7).

3. Type in Noor* inside box Find What to find all the name starting with Noor.

4. Click Find Next button. Name Noorul-Aini bt Ambak will be highlighted at namefield (refer figure 8).

17/30

Figure 6

Icon Find

Figure 7

Figure 8

 

Page 28: ICTLSM Database Module

8/2/2019 ICTLSM Database Module

http://slidepdf.com/reader/full/ictlsm-database-module 28/28

 ______________________________________________________ 

5. Click Find Next button to find similar name with Noor. Name Noor Asiah btZakaria will be highlighted.

6. You can repeat step 3 to find other record.

7. Click File and Close to end this session.

Exercise Module 3

1. Based on your exercise in module 2 (“Curriculum Data”).

a. Add 3 new recordsb. Add 2 new fields

c. Find records

- Finish -