Microsoft Access 2010 Crash Course Part 1 Academic Health Center Training [email protected]...

17
Microsoft Access 2010 Crash Course Part 1 Academic Health Center Training [email protected] (352) 273-5051

Transcript of Microsoft Access 2010 Crash Course Part 1 Academic Health Center Training [email protected]...

Microsoft Access 2010Crash Course Part 1

Academic Health Center [email protected](352) 273-5051

Database Vocabulary

What is a database?• A structured collection of related data • Filing cabinets, address books, etc.• In Access, your Database is your collection of

related tables

Database Vocabulary

• Table Name: Barry HarrisPhone: 392-5555Email: [email protected]

Name: Barry HarrisPhone: 392-5555Email: [email protected]

Name: Barry Harris• Field

• Record–A collection of data

about an individual item

–A single item of data common to all records

– A set of related records

Example of a Table

Records

Fields

Name GatorLink Phone College

Smith rsmith 392-3900 Pharmacy

Thomas bthomas 392-5555 Medicine

Van Winkle sleepyguy 846-5656 PHHP

Why Use Access?

• Familiar look and feel of Windows

• Easy to start building simple databases

• Can build sophisticated systems

• It’s already on your computer

• True relational database

What is a Relational Database?

• A relational database is a collection of tables from which data can be accessed in many different ways without having to reorganize the database tables. – That is, once relationships are created, tables can

“talk” to each other. We can link (relate) the tables to find:• Which doctors have seen a patient• Which students are in a class• Which item is selling the most on Friday’s

Basic Design Rule

LastNameSmithSmithSmithThomasVan Winkle

If you want to link multiple tables together, you need establish unique records, otherwise the database can’t tell which record you may be referring to.

LastName EmergencyContact

Smith Mary Anne Smith

• Unique Records

?

Primary KeysLastName GatorLink Phone CollegeSmith rsmith 273-5051 PharmacyThomas bthomas 392-5555 MedicineVan Winkle sleepyguy 846-5656 PHHP

To ensure that each record is unique in each table, we can set one field to be a Primary Key field.

A Primary Key is a field that that will contain no duplicates and no blank values.

Looking at the table above, what would be the best Primary Key?

Primary KeysLastName GL ID Phone CollegeSmith rsmith 273-5051 PharmacyThomas bthomas 392-5555 MedicineVan Winkle sleepyguy 846-5656 PHHP

While each column in this particular data set has unique data, the field that will work best for us is GL ID (GatorLink). Many employees will work for the same college, have the same last name and possibly even share telephone numbers, but each employee should have a unique GatorLink ID.

When there is not a unique field in your data set, you can use an AutoNumber. Access can create incremented or random AutoNumbers for your primary key.

Basic Design Rules• Unique Records

ID LastName GatorLink Phone College1 Smith rsmith 3-5051 Pharmacy2 Smith rsmith 273-5051 COP3 Smith rsmith 273-5051 Pharmacy4 Thomas bthomas 392-5555 Medicine5 Van Winkle sleepyguy 846-5656 PHHP

We use the unique primary key as our link between our tables, this helps ensure we connect to the correct record.

Emp ID EmergencyContact

2 Mary Anne Smith

Data View/Design View

Tables Forms

Queries Reports

The Access Database Window

The navigation pane on the left side of the window organizes all the database objects

Introducing Tables• Database is a collection of Tables• Data Storage• The foundation of your database

Introducing Queries• A means of asking questions (querying) of your data• Can look across a number of Tables and other Queries• Can perform Calculations and Combine fields

Introducing Forms• A friendlier view of the database• Used for data input, menus, display and printing• Can perform Calculations and Combine fields

Introducing Reports• Output of information in a printed report

• Allows you to group and summarize data

• Can perform Calculations and Combine fields

• Cannot Edit Data

• Can Make Labels

Working TogetherTables Queries

Patients

First Name:

Last Name:

Gender:

Birth Date:

Phone #:

Forms

Reports

Patients

Report