Microsoft®
Access 2003
®
&
MARAN ILLUSTRATED™ Microsoft® Access 2003 © 2003-2005 by maranGraphics Inc. All rights reserved. No part of this book may be reproduced or transmitted in any form or by any means, electronic, mechanical or otherwise, including by photocopying, recording, or by any storage or retrieval system without prior written permission from maranGraphics, except for the inclusion of brief quotations in a review. Distributed in the U.S. and Canada by Thomson Course Technology PTR. For enquiries about Maran Illustrated™ books outside the U.S. and Canada, please contact maranGraphics at
[email protected] For U.S. orders and customer service, please contact Thomson Course Technology at 1-800-354-9706. For Canadian orders, please contact Thomson Course Technology at 1-800-268-2222 or 416-752-9448. ISBN: 1-59200-872-0 Library of Congress Catalog Card Number: 2005921493 Printed in the United States of America 05 06 07 08 09 BU 10 9 8 7 6 5 4 3 2 1
Trademarks maranGraphics is a registered trademark of maranGraphics Inc. Maran Illustrated, the Maran Illustrated logos and any trade dress related to or associated with the contents or cover of this book are trademarks of maranGraphics Inc. and may not be used without written permission. The Thomson Course Technology PTR logo is a trademark of Course Technology and may not be used without written permission. All other trademarks are the property of their respective owners.
Permissions Microsoft ©2003 Microsoft Corporation. All rights reserved.
Important maranGraphics and Thomson Course Technology PTR cannot provide software support. Please contact the appropriate software manufacturer’s technical support line or Web site for assistance.
DISCLAIMER: PURCHASERS, READERS OR USERS OF THIS BOOK AGREE TO BE BOUND BY THE FOLLOWING TERMS.
INFORMATION CONTAINED IN THIS BOOK HAS BEEN OBTAINED BY MARANGRAPHICS AND FROM SOURCES BELIEVED TO BE RELIABLE. HOWEVER, NEITHER MARANGRAPHICS INC. NOR THOMSON COURSE TECHNOLOGY PTR NOR ANY OF THEIR RESPECTIVE AFFILIATES, DISTRIBUTORS, EMPLOYEES, AGENTS, CONTENT CONTRIBUTORS OR LICENSORS, IF ANY, MAKE ANY REPRESENTATION, WARRANTY, GUARANTEE OR ENDORSEMENT AS TO THE INFORMATION CONTAINED IN THIS BOOK OR AS TO THIRD-PARTY SUPPLIERS REFERENCED IN THIS BOOK, INCLUDING WITHOUT LIMITATION REGARDING THEIR ACCURACY, CORRECTNESS, TIMELINESS, RELIABILITY, USEFULNESS OR COMPLETENESS, OR THE RESULTS THAT MAY BE OBTAINED FROM THE USE OF THIS BOOK, AND DISCLAIM ALL EXPRESS, IMPLIED OR STATUTORY WARRANTIES, INCLUDING IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS OR SUITABILITY FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. THE SUBJECT MATTER OF THIS BOOK IS CONSTANTLY EVOLVING AND THE INFORMATION PROVIDED IN THIS BOOK IS NOT EXHAUSTIVE. IT SHOULD NOT BE USED AS A SUBSTITUTE FOR CONSULTING WITH A QUALIFIED PROFESSIONAL WHERE PROFESSIONAL ASSISTANCE IS REQUIRED OR APPROPRIATE, INCLUDING WHERE THERE MAY BE ANY RISK TO HEALTH OR PROPERTY, AND THE PURCHASER, READER OR USER UNDERSTANDS AND ACKNOWLEDGES THAT THE AFOREMENTIONED PARTIES ARE NOT HEREBY PROVIDING ANY PROFESSIONAL ADVICE, CONSULTATION OR OTHER SERVICES. IN NO EVENT WILL ANY OF MARANGRAPHICS INC., THOMSON COURSE TECHNOLOGY PTR, OR ANY OF THEIR RESPECTIVE AFFILIATES, DISTRIBUTORS, EMPLOYEES, AGENTS, CONTENT CONTRIBUTORS OR LICENSORS BE LIABLE OR RESPONSIBLE FOR ANY DAMAGES INCLUDING ANY DIRECT, INDIRECT, SPECIAL, CONSEQUENTIAL, INCIDENTAL, PUNITIVE OR EXEMPLARY LOSSES, DAMAGE OR EXPENSES (INCLUDING BUSINESS INTERRUPTION, LOSS OF PROFITS, LOST BUSINESS, OR LOST SAVINGS) IRRESPECTIVE OF THE NATURE OF THE CAUSE OF ACTION, DEMAND OR ACTION, INCLUDING BREACH OF CONTRACT, NEGLIGENCE, TORT OR ANY OTHER LEGAL THEORY.
maranGraphics and Thomson Course Technology PTR have attempted throughout this book to distinguish proprietary trademarks by following the capitalization style used by the source. However, we cannot attest to the accuracy of the style, and the use of a word or term in this book is not intended to affect the validity of any trademark.
Copies Educational facilities, companies, and organizations located in the U.S. and Canada that are interested in multiple copies of this book should contact Thomson Course Technology PTR for quantity discount information. Training manuals, CD-ROMs, and portions of this book are also available individually or can be tailored for specific needs.
®
maranGraphics Inc. 5755 Coopers Avenue Mississauga, Ontario L4Z 1R9 www.maran.com
Thomson Course Technology PTR, a division of Thomson Course Technology 25 Thomson Place Boston, MA 02210 http://www.courseptr.com
maranGraphics is a family-run business.
At maranGraphics, we believe in producing great computer books––one book at a time. Each maranGraphics book uses the award-winning communication process that we have been developing over the last 30 years. Using this process, we organize screen shots, text and illustrations in a way that makes it easy for you to learn new concepts and tasks.
We spend hours deciding the best way to perform each task, so you don’t have to! Our clear, easy-to-follow screen shots and instructions walk you through each task from beginning to end.
We want to thank you for purchasing what we feel are the best computer books money can buy. We hope you enjoy using this book as much as we enjoyed creating it!
Our detailed illustrations go hand-in-hand with the text to help reinforce the information. Each illustration is a labor of love––some take up to a week to draw!
Sincerely, The Maran Family
We would love to hear from you! Send your comments and feedback about our books to
[email protected]
Please visit us on the Web at:
www.maran.com
CREDITS Author: Ruth Maran
Post Production: Robert Maran
Access 2003 Update Director: Kelleigh Johnson
President, Thomson Course Technology: David R. West
Project Manager: Judy Maran Editing and Screen Captures: Raquel Scott Roderick Anatalio Adam Giles Layout Designer: Richard Hung
Senior Vice President of Business Development, Thomson Course Technology: Andy Shafran Publisher and General Manager, Thomson Course Technology PTR: Stacy L. Hiquet
Illustrator & Screen Artist: Russ Marini
Associate Director of Marketing, Thomson Course Technology PTR: Sarah O’Donnell
Illustrator, Screen Artist & Assistant Layout Designer: Steven Schaerer
National Sales Manager, Thomson Course Technology PTR: Amy Merrill
Indexer: Raquel Scott
Manager of Editorial Services, Thomson Course Technology PTR: Heather Talbot
ACKNOWLEDGMENTS
Thanks to the dedicated staff of maranGraphics, including Roderick Anatalio, Adam Giles, Richard Hung, Kelleigh Johnson, Wanda Lawrie, Jill Maran, Judy Maran, Robert Maran, Ruth Maran, Russ Marini, Steven Schaerer, Raquel Scott and Roxanne Van Damme. Finally, to Richard Maran who originated the easy-to-use graphic format of this guide. Thank you for your inspiration and guidance.
This page intentionally left blank
TABLE OF CONTENTS
1
Chapter
GETTING STARTED
COMPACT COMPACT
L
K
J
I
H
G
F
E
D
C
B
A
A-L
Chapter
2
Employee # 5
HR100 2 PR555 33 ADV20 5 HR120
ed Date Hir 12/2/90 ng 6es/ ources man R 3 ising Advert 11/25/95 s Payroll source an1R/9e5 Hu2m/2 ll 7 3/9 yro P7a/1 g ert3isin Ad5v/9 3/2 ll ro y 6 a /9 6/28P 8 /9 2 /1 1 1
30 ADV1o9urs/Wk H 0 PR557 9 40 HR300 2 PR342 25
8/16/89
5 ADV10 4 PR20
Introduction to Access ........................................4 Start Access ......................................................5 Parts of a Database ..........................................6 Plan a Database ................................................8 Create a Database Using the Database Wizard..10 Create a Blank Database..................................16 Open a Database............................................18 Using the Database Window ............................20 Rename a Database Object ..............................22 Delete a Database Object ................................23 Minimize a Window ........................................24 Display or Hide a Toolbar ................................25 Search for a Database ....................................26 Back Up a Database ........................................28 Getting Help ..................................................30 CREATE TABLES
Create a Table in the Datasheet View ................34 Create a Table Using the Table Wizard..............38 Open a Table ..................................................42 Change a Column Width..................................43 Rename a Field ..............................................44 Rearrange Fields..............................................45 Add a Field ....................................................46 Delete a Field..................................................47 Change the Appearance of a Table ..................48
3
Chapter
EDIT TABLES
ORDERS Table Company Name
Order ID 1
Vitamins
Petterson Inc.
Bulk Dry Food
3
Martin Vet Supplies
Diet Dog Food
4
Greg’s Pet Store
5-Variety Biscu
5
Pet Superstore
Canned Dog Fo
6
Feline Foods Inc.
Dry Cat Food
7
Weasels R Us
Ferret Pellets
8
Purrrfect Portions
Dry Cat Food
9
Doggone Yummy Inc.
Steak-flavored
10 11
Jim’s Pets Allen’s Dog Kennel
Hamster Treats Puppy Kibble
12
B&T Food Suppliers
Gerbil Mix
13
Pet Superstore
Parrot Food
14
Kitty-Mart
Dry Cat Food
15
Canine Nutrition Inc.
Rawhide Chew
Chapter Invoice
Prod
Pet Superstore
2
4
Numbe r
23452 Grant Lewis Smith Grant Lewis Smith Grant Lewis Smith Fraser Turner Fraser Turner Morris Fraser
Preparation Time Recipe
Time
Servings Calories
Move Through Data ........................................52 Select Data ....................................................54 Edit Data ........................................................56 Zoom Into a Cell..............................................58 Display a Subdatasheet ....................................59 Check Spelling ................................................60 Move or Copy Data ........................................62 Add a Record ................................................64 Delete a Record ..............................................65 Change the Font of Data ..................................66 Hide a Field ....................................................68 Freeze a Field ................................................70 DESIGN TABLES
Change the View of a Table..............................74 Add a Field ....................................................76 Delete a Field..................................................78 Rearrange Fields..............................................79 Display Field Properties ....................................80 Add a Field Description....................................81 Change a Data Type........................................82 Select a Format ..............................................84 Change the Field Size ......................................86 Change the Number of Decimal Places ..............88 Add a Caption ................................................90 Set a Default Value ..........................................91 Data Entry Required ........................................92 Add a Validation Rule ......................................94 Create an Input Mask ......................................96 Create a Field to Store Pictures........................102 Create a Lookup Column ................................106 Create a Yes/No Field ..................................110 Create a Hyperlink Field ................................114 Using Smart Tags ..........................................120
TABLE OF CONTENTS
Chapter
5
ESTABLISH RELATIONSHIPS
View Object Dependencies ............................124 Set the Primary Key........................................126 Create Relationships Between Tables................128 Enforce Referential Integrity ............................132
Chapter Customer ID
Last Name
First Name
1 Ryan 2 Erin
Smith Baker
3 Josh
Nelson
Address
City
258 Linton Ave. New York Boston 50 Tree Lane
State/Province Postal Code
NY
4 Carl
Davis
MA 68 Cracker Ave. San Francisco CA NV 47 Crosby Ave. Las Vegas
5 Emily
Ross
26 Arnold Cres. Jacksonville
6 Sue
Grant
401 Idon Dr.
Nashville
6 10010 02117
FL
94110 89116 32256
TN
37243
Emily Ross
Chapter
7 Design View Form View Datasheet View PivotTable View
Tribute Electronics : ...
Order Details
12:00 PM
PivotChart View
Work Phone
Client Name Address City
Home Phone
State/Province Postal Code
FielFideld
NewNeFiw Fiel eld d
Field
CREATE FORMS
Create a Form Using an AutoForm ..................136 Create a Form Using the Form Wizard ............138 Open a Form ................................................144 Move Through Records ..................................145 Edit Data ......................................................146 Add a Record ..............................................148 Delete a Record ............................................149
DESIGN FORMS
Change the View of a Form ............................152 Move or Resize a Control ..............................154 Delete a Control ............................................156 Change the Size of a Form ............................157 Add a Field ..................................................158 Add a Label ..................................................159 Change Label Text ........................................160 Bold, Italicize or Underline Data......................161 Change the Font of Data ................................162 Change the Size of Data ................................163 Change the Color of a Control........................164 Change the Alignment of Data ........................166 Undo Changes ..............................................167 Add a Picture ................................................168 Apply Conditional Formatting..........................170 Apply an AutoFormat ....................................172
Chapter
8
FIND DATA
Sort Records..................................................176 Find Data......................................................178 Replace Data ................................................180 Filter by Selection ..........................................182 Filter by Input ................................................184 Filter by Exclusion ..........................................185 Filter by Form ................................................186
Chapter
9
Query
First Name Last Name
State
Dianne
Morris
CALIFORNIA
Emily
Ross
CALIFORNIA
Matt
Cole
CALIFORNIA
Jason
Cook
CALIFORNIA
Please
Enter the s you want to
CALIFOR
CREATE QUERIES
Create a Query in the Design View ................192 Create a Query Using the Simple Query Wizard ......................................................196 Change the View of a Query ..........................202 Open a Query ..............................................204 Rearrange Fields............................................205 Add Fields ....................................................206 Delete a Field................................................208 Hide a Field ..................................................209 Sort Query Results ........................................210 Using Criteria to Find Records ........................211 Using Multiple Criteria to Find Records ............212 Examples of Criteria ......................................214 Display Highest or Lowest Values ....................216 Perform Calculations ......................................218 Using Parameters ..........................................220 Summarize Data ............................................222 Find Unmatched Records ................................226
TABLE OF CONTENTS
10
Chapter PivotTable Quarter 1
+ -
Sales
Region Central
+ -
+ -
North
0 $29,000.0 0 $16,000.0
Quarter 2 Sales
0 $19,000.0 0 $19,000.0 Cains $14,600.00
$18,000.00 $15,000.00 $16,000 Pat 0 .00 $21,000.0 $202,9 0 $23,000.0 $22,000.0 00.00 0 $23,500.0 $19,000.00 00
11
T
Table 1
le 2 Tab
Chapter Meal
1 Chicken Stir-fry Dinner
12
Vegetarian No
2 Omelet
Breakfast
Yes
3 Veggie Pizza
Lunch
Yes
4 Lasagna
Dinner
5 Pancakes
Breakfast
6 Pork Chops
Dinner
No
7 Garden Salad
Lunch
Yes
8 Fruit Salad
Breakfast
Yes
No Yes
250mL 150mL 50mL
AD3 PUSH
Using the PivotTable View ..............................232 Using the PivotChart View ..............................238
+-
Chapter
Recipe ID Recipe Name
USING THE PIVOTTABLE AND PIVOTCHART VIEWS
en enickCen hick Chyick Chry Pry Trr Cur ❧ ❧❧ ❧❧ ❧❧ ❧❧
❧❧❧❧❧ ❧❧❧❧❧
CREATE REPORTS
Create a Report Using the Report Wizard ........246 Create a Report Using an AutoReport ..............254 Open a Report ..............................................256 Move Through Pages ....................................257 Change the View of a Report ..........................258 Zoom In or Out ............................................260 Apply an AutoFormat ....................................261 Add a Picture ................................................262
PRINT INFORMATION
Preview Before Printing ..................................266 Change Page Setup ......................................268 Print Information ............................................270 Create Mailing Labels ....................................272
Chapter
13
Create a Data Access Page ............................280 Change the View of a Data Access Page ........286 Open a Data Access Page..............................288 Add a Title....................................................289 Move Through Records ..................................290 Apply a Theme..............................................292 Rename a Data Access Page ..........................294 Delete a Data Access Page ............................295
mG
8
Product ID
Sports Superstore
2
Product ID
Product Name DVD Category:
Video
Unit Price Units In Stock
CREATE DATA ACCESS PAGES
$139.99
Television Charlotte
Category:
VideoNC
Unit Price
80
2354 Elm Ave.
Product Name
Units In Stock
Products 2 of 12
28228-
125 Customers 8 of 12 Products 3 of 12
AD3
PUSH
AD3
POWER
RESET
3
$799.00
This page intentionally left blank
This page intentionally left blank
COMPACT COMPACT
Product
ID
Company
Product
Unit Price
Quantit
AB DAT
CHAPTER 1
Getting Started Are you ready to begin using Microsoft Access 2003? This chapter will help you get started. Introduction to Access ..........................4 Start Access........................................5 Parts of a Database ............................6 Plan a Database ................................8 Create a Database Using the Database Wizard ..........................10
ntity
Create a Blank Database ..................16 Open a Database ............................18 Using the Database Window ..............20 Rename a Database Object................22 Delete a Database Object ..................23 Minimize a Window..........................24
TAB
ASE
Display or Hide a Toolbar ..................25
RTS
REPO
S FORM RIES QUE LES TAB
Search for a Database ......................26
E
S A B A DAT
Back Up a Database ........................28 Getting Help ....................................30
INTRODUCTION TO ACCESS
Microsoft® Access 2003 is a database program that allows you to store and manage large collections of information. Access provides you with all the tools you need to create an efficient and effective database.
Many individuals use databases to store personal information such as addresses, music collections, recipes and wine lists.
COMPACT COMPACT
L
K
J
I
H
G
F
E
D
C
B
Companies use databases to store information such as mailing lists, client orders, expenses, inventory and payroll.
A
A-L
DATABASE APPLICATIONS
Store Information
Find Information
Analyze and Print Information
A database stores and manages a collection of information related to a particular subject or purpose. You can efficiently review, add, update and organize the information stored in a database.
You can instantly locate information of interest in a database. For example, you can find all clients with the last name "Smith." You can also perform more advanced searches, such as finding all clients living in California who purchased more than $1,000 of your products last year.
You can perform calculations on the information in a database to help you make quick, accurate and informed decisions. You can neatly present the information in professionally designed reports. First Quarte Category
r Sales for
Hockey Equ ipment
Products Products Products
Products Products Products
Products
Products Products Products Products
Products
Customer
Atherley
Last NameFirst NameStreet
Customers
4
Customers Customers
State
Zip Code
Lang
Kristin
50 Tree Lane
Boston
MA
02117
Oram
Derek
68 Cacker Ave.
San Francisco
CA
94110
Russel
1 Hollywood Blvd.
Gray Atherley Smith Talbot
Customers
City
Cincinnati
OH
Las Vegas
NV
John
258 Linton Ave.
New York
NY
10010
Mark
26 Arnold Cres.
Jacksonville
FL
32256
Peter
47 Cosby Ave.
Smith
45217 89116
Coleman
Duane
401 Idon Dr.
Nashville
TN
37243
Sanvido
Dean
16 Hoover Cres.
Greenwich
CT
06831
Slater
Mark
468 Starewell Rd.
Salem
OR
97304
Pozeg
Dan
10 Heldon St.
Atlanta
GA
30368
Talbot
Hretchka
Gombocz
Steve
890 Apple St.
San Diego
Sandor
18 Goulage Ave.
Los Angeles
CA
Boshart
Mark
36 Buzzard St.
Denver
CO
80207
Jaklitsch
Janet
15 Bizzo Pl.
Portland
OR
CA
97203
92121
Lippert
Diane
14 Bizzo Pl.
Las Vegas
NV
89125
Allison
Murray
RR#5
Nashville
TN
37243
Dumas
Jeff
14 Travis Pl.
Cincinnati
OH
45262
90032
TOTAL Baseball Equipm
TOTAL
Product Product Sales
ent Helmets Gloves Shoes Pants Bats Jerseys Batting Glov es Hats
TOTAL Racquet
2002
Skates Helmets Shoulder Pads Elbow Pads Shin Pads Jock Strap s Masks Sticks Gloves Pants
INFORMATION
Sports Badminto n Squash RacqRacquets Tennis Racq uets Racquetb uets all Indoor Cou Racquets Outdoor rt Shoes Cou Tennis Balls rt Shoes Squash Balls Racquetb all Balls
3450.00 2453.88 2000.00 1234.88 4000.00 8000.00 1256.95 8000.00 4560.99 3000.00 37956.70 234.65 3678.65 3456.23 457.99 2345.89 5678.89 345.78 7890.65 24088.73 3456.78 2345.67 6578.98 345.67 9876.54 10000.4 0 500.00 345.00 65.00 33514.04
START ACCESS
Getting Started
1
You can start Access to create a new database or work with a database you previously created.
When you finish using Access, you can exit the program. You should always exit all open programs before turning off your computer. START ACCESS
Microsoft Office Microsoft Office Access 2003
All Programs Log Off
Recycle Bin
Turn Off Computer
12:00 PM
⁄ Click start. ¤ Click All Programs to view a list of the programs on your computer. Note: If you are using an earlier version of Windows, click Programs in step 2.
‹ Click Microsoft Office.
› Click Microsoft Office Access 2003.
The Microsoft Access window appears.
12:00 PM
Microsoft Access
The Getting Started task pane appears each time you start Access, allowing you to quickly perform common tasks.
EXIT ACCESS
⁄ When you finish using Access, click to close the Microsoft Access window and exit Access.
A button for the Microsoft Access window appears on the taskbar.
5
PARTS OF A DATABASE
A database consists of objects such as tables, forms, queries, reports and pages.
Tables
A table stores a collection of information about a specific topic, such as a mailing list. You can have one or more tables in a database. A table consists of fields and records.
6
Address ID
First Name
Last Name
Address
City
State/Province Postal Code
1
Janet
Smith
258 Linton Ave. New York
NY
10010
2
Mark
Taylor
50 Tree Lane
MA
02117
3
Nancy
King
68 Cracker Ave. San Francisco CA
94110
4
Jack
Adams
47 Crosby Ave. Las Vegas
NV
89116
5
Amy
Martin
26 Arnold Cres. Jacksonville
FL
32256
6
Kevin
Turner
401 Idon Dr.
Nashville
TN
37243
7
Julie
Brown
10 Heldon St.
Atlanta
GA
30375
8
Matt
Cole
36 Buzzard St. Boston
MA
02118
9
Frank
Hill
15 Bizzo Pl.
New York
NY
10020
10
Erin
Baker
890 Apple St.
San Diego
CA
92121
Boston
Field
Record
A field is a specific category of information in a table, such as the first names of all your customers.
A record is a collection of information about one person, place or thing in a table, such as the name and address of one customer.
Getting Started
1
Forms
Queries
Forms provide a quick way to view, enter and edit information in a database by presenting information in an attractive, easy-to-use format. Forms display boxes that clearly show you where to enter and/or edit information. Forms usually display one record at a time.
Queries allow you to find information of interest in a database. You can enter criteria in a query to specify what information you want to find. For example, you can create a query to find every customer who lives in California.
Home Phone
(904) 555-6974
First Name
Amy
Work Phone
(904) 555-3636
Last Name
Martin
Work Extension
471
Address
26 Arnold Cres.
Fax Number
(904) 555-2508
Address ID
5
? Address ID
First Name
10 Jack 11 Erin 3 Lisa 13 Julie
Last Name
Adams Baker Bell Brown
City
Jacksonville
State/Province
FL
Postal Code
32256
61 Jason
Cook
Country
USA
71 Carl
Davis
Spouse Name
John
18 Simon
Evans
6 Paul
Fraser
76 Sue
Grant
14 Alan
Carter
42 Matt
Cole
Reports
Pages
Reports are professional-looking documents that summarize information from a database. You can perform calculations in a report to help you analyze the data. For example, you can create a report that displays the total sales for each product.
Data access pages are Web pages that connect directly to the information in your database. You can use these pages to view, enter, edit and analyze data in your database from the Internet or your company's intranet.
First Quarter Sales Baseball Bats
Product Month
Quantity Sold
January
3200
$29.99
February
3000
$29.99
March
2000
$29.99
Unit Price
Summary for 'Product'= Baseball Bats (3 detail records) 8200
Sum
Baseball Gloves
Product Month January
Quantity Sold 3200
Unit Price $39.99
7
PLAN A DATABASE
You should take the time to plan your database. A well-planned database helps ensure that you will be able to perform tasks efficiently and accurately.
Determine the Purpose of Your Database
Determine the Tables You Need
Decide what information you want your database to store and how you plan to use the information. If colleagues, friends or family members will use the database, you should consult with them to determine how they plan to use the database.
Gather all the information you want to store in your database and then divide the information into separate tables. Each table should contain information for only one subject, such as a list of customer addresses. The same information should not appear in more than one table in your database. You can work more efficiently and reduce errors if you only need to update information in one table. OR DE
ADDR
Table ESSES
y ID Compan 1 2 3 4 5 6 7
Address Ave. Company 258 Linton store e Pet Super Tree Lan 50 . n Inc r Ave. Petterso cke Cra s 68 Supplie Ave. Martin Vet 47 Crosby t Store Pe g's Gre Cres. 26 Arnold store Pet Super Dr. 401 Idon ds Inc. Feline Foo St. 10 Heldon Us R Weasels d St. 36 Buzzar
ct 8 Purrrfe
Por
tions
ADDRESSES
8
City rk New Yo Boston
ncisco San Fra Las Vegas lle Jacksonvi Nashville Atlanta Boston
RS Ta ble
Postal Code 10010
Order ID 02-453
Comp any ID
02117 94110
02-454
1
02-455
2
Vitamins Bulk Dry
89116
02-456
3
Diet Do
15
32256
02-457
4
30
37243 30375
02-458
5
02-459
6
02118
02-460
5-Variety Biscuits Canned Dog Food Dry Cat Food Ferret Pe llets Dry Cat Food
7 8
Produc t
Quantity
Food g Food
12
Unit Pri ce
50
$20.00 $18.00 $10.00 $3.50
24
$1.00
40
Wholesal$4e.00 Pe Supplies t
30
24 Date: 4/4/0 2
Company Product Feline Foods Dry Cat Inc. Foo d
Terms: Net on ove30 days. rdue acc 2% per ounts. month
$6.50
$4ce.00 Invoi #: 681 Qty. 40
Price $160.00
Getting Started
1
A field is a specific category of information in a table, such as the last name of every client.
order #
Province quantity Postal code
Determine the Fields You Need
S
FIELD
➢ Each field should relate directly to the subject of a table. Address
➢ Make sure you break information in a table into its smallest parts. For example, break down names into two fields called First Name and Last Name.
➢ Do not include a field that contains data you can calculate using other fields. For example, if a table includes a Unit Price field and a Quantity field, do not include a field that multiplies the values in these two fields. Access can perform the calculations for you and will update the calculations each time you change values in the fields.
ID Last Name
s res
Add
City
➢ Try to keep the number of fields in a table to a minimum. Tables with many fields increase the time Access takes to process information.
Determine the Primary Key in Each Table
Determine the Relationships Between Tables
Each table in your database should have a primary key. A primary key is one or more fields that uniquely identifies each record in a table. For example, the primary key in a table containing employee information can be the social security number for each employee.
Relationships between tables allow Access to bring together related information stored in separate tables in your database. For example, you can create a relationship between the Customers table and the Orders table. You usually relate the primary key in one table to a matching field in another table to create a relationship.
# Social Security 111-11-1111
First Name
Jack
Last Name
Address
City
Adams
York 258 Linton Ave. New 50 Tree Lane
Boston
State/Province
NY MA
222-22-2222
Frank
Hill
333-33-3333
Kevin
Turner
San Francisco CA 68 Cracker Ave.
Harris
47 Crosby Ave.
444-44-4444
Linda
600-60-6000
Carl
Davis
Jacksonville 26 Arnold Cres.
777-77-7777
Alan
Carter
Mary
Wilson
10 Heldon St.
888-88-8888
Young
Boston 36 Buzzard St.
999-99-9999
Janet
000-00-0000
Lisa
Bell
Paul
Fraser
000-11-2222
401 Idon Dr.
15 Bizzo Pl. 890 Apple St.
Las Vegas
NV FL
Nashville
TN
Atlanta
GA
New York San Diego
MA NY CA
Postal Code
10010 02117 94110 89116 32256 37243 30375 02118 10020
ORDERS Table
CUSTOMERS Table Company ID
Company Name
Address
City
Postal Code
Order ID
Company ID
02-453
1
Vitamins
2
$20.00
02-454
2
Bulk Dry Food
2
$18.00
3
Diet Dog Food
1
$10.00
1
Pet Superstore
258 Linton Ave. New York
10010
2
Petterson Inc.
50 Tree Lane
02117
3 Martin Vet Supplies 68 Cracker Ave. San Francisco 94110
02-455
Boston
Product
Quantity
Unit Price
89116
02-456
4
5-Variety Biscuits
3
$3.50
32256
02-457
5
Canned Dog Food
7
$1.50
6 Feline Foods Inc. 401 Idon Dr.
Nashville
37243
02-458
6
Dry Cat Food
2
$4.00
7 Weasels R Us
Atlanta
30375
02-459
7
Ferret Pellets
1
$6.50
Boston
02118
02-460
8
Dry Cat Food
3
$4.00
4
Greg's Pet Store 47 Crosby Ave.
5
Pet Superstore
Las Vegas
26 Arnold Cres. Jacksonville
10 Heldon St.
8 Purrrfect Portions 36 Buzzard St.
92121
9
CREATE A DATABASE USING THE DATABASE WIZARD
You can use the Database Wizard to quickly and easily create a database. The wizard saves you time by creating the tables, forms, queries and reports for your database.
TS REPOR
You can use the Database Wizard to create many types of databases, such as databases for contact management, expenses, inventory control and order entry.
IES
QUER
S
FORM
S TABLE
You can have only one database open at a time. Access will close a database displayed on your screen when you create a new database. CREATE A DATABASE USING THE DATABASE WIZARD
Expenses
Microsoft Access
⁄ Click to create a new database. The New File task pane appears.
12:00 PM
¤ Click On my computer to create a database using the Database Wizard.
Microsoft Access
The Templates dialog box appears.
ˇ Click OK to create the database.
‹ Click the Databases
The File New Database dialog box appears.
tab.
› Click the database
10
12:00 PM
template that best describes the type of database you want to create.
Getting Started
Tip
How can I quickly select a database template I recently used?
Tip
The New File task pane displays the names of the last four database templates you used. To display the New File task pane, perform step 1 on page 10.
1
How can I get more database templates?
When you are connected to the Internet, click Templates on Office Online on the New File task pane. To display the New File task pane, perform step 1 on page 10. A Web page will appear, allowing you to obtain more database templates that you can use.
⁄ To select a database template you recently used, click the name of the template.
Microsoft Access
Á Type a name for your database. This area shows the location where Access will store your database. You can click this area to change the location.
12:00 PM
This area allows you to access commonly used locations. To access a commonly used location, click the location.
ABC Corporation : Da...
The Database Wizard appears.
12:00 PM
° Click Next to continue.
This area describes the type of information the database will store.
‡ Click Create to create the database. 11
CREATE A DATABASE USING THE DATABASE WIZARD
The Database Wizard displays the fields that each table in your database will include. You can choose to include additional fields in each table.
nal
Optio
Opti
onal
A field is a specific category of information in a table, such as the last names of all your customers. CREATE A DATABASE USING THE DATABASE WIZARD (CONTINUED)
Expense report information
Expense report information
Business Purpose
ABC Corporation : Da...
This area displays the tables Access will include in your database.
· Click a table to display the fields in the table.
12
12:00 PM
This area displays the fields in the table you selected. The fields displaying a check mark (✔) are required fields and must be included in the table. The fields shown in italics are optional.
ABC Corporation : Da...
‚ To add an optional field to the table, click the box ( ) beside the field ( changes to ). Repeat this step for each optional field you want to include in the table.
12:00 PM
To add optional fields to other tables in the database, repeat steps 9 and 10 for each table.
— Click Next to continue.
Getting Started
Tip
1
Can I remove a required field from a table in the Database Wizard?
No. You can remove a required field from a table only after you finish creating the database. When you try to remove a required field in the Database Wizard, a message will appear, stating that the field is required and must be selected. To remove a field from a table after you finish creating the database, see page 47.
Address Address ID First Name Last Name 1 Jack Adams 258 Linton Ave. 2 Erin Baker 50 Tree Lane 3 Lisa Bell 68 Cracker Ave. 4 Julie Brown 47 Crosby Ave. 5 Alan Carter 26 Arnold Cres. 6 Matt 7 Jason
Cole
8 Carl
Davis
Cook
City
State/Province
New York
NY
Boston
MA
San Francisco CA
NV Las Vegas Pos Jacksonville tal C FL ode 100 TN Nashville 10 021 GA 10 Heldon St. Atlanta 17 941 10 MA 36 Buzzard St. Boston 891 16 322 56 372 43 303 75 02 401 Idon Dr.
Blends
Corporate
ABC Corporation : Da...
12:00 PM
ABC Corporation : Da...
± Click the style you want
¡ Click Next to continue.
™ Click the style you
to use for screen displays.
You can click Back at any time to return to a previous step and change your selections.
want to use for printed reports.
This area displays a sample of the style you selected.
12:00 PM
£ Click Next to continue.
This area displays a sample of the style you selected.
13
CREATE A DATABASE USING THE DATABASE WIZARD
When the Database Wizard finishes creating your database, Access displays a switchboard that you can use to perform common tasks in the database.
3850 +192 0=57 70
CD
CD
Multimedia
CD Multimedia
ienc e
Education
Sc
Politics
ia imed Mult
A switchboard is a menu that offers a list of choices. CREATE A DATABASE USING THE DATABASE WIZARD (CONTINUED)
ABC Corporation : Da...
¢ This area displays the title of your database. To use a different title, type the title.
14
12:00 PM
∞ Click Next to continue.
ABC Corporation : Da...
The Database Wizard indicates that you have provided all the information needed to create your database.
12:00 PM
§ Click Finish to create your database.
Getting Started
Tip
Why does this dialog box appear when I finish using the Database Wizard?
Tip
Access needs you to enter information, such as your company name and address, to finish setting up the database.
1
Do I have to use the Main Switchboard to work with my database?
No. Instead of using the Main Switchboard window, you can use the Database window to work with your database. To quickly display the Database window at any time, press the F11 key. For more information on the Database window, see page 20.
To close the dialog box and display a form that provides areas for you to enter your information, click OK. To enter data into a form, see page 148.
ABC Corporation : Da...
Main Switchboard
Access creates the objects for your database, including tables, forms, queries and reports. The Main Switchboard window appears, displaying options you can select to perform common tasks in the database.
12:00 PM
¶ To perform a task, click the task you want to perform.
ABC Corporation...
Main Switchboard
The database object that allows you to perform the task appears. Note: If a list of additional tasks appears, repeat step 19 to select the task you want to perform.
Expense Report...
12:00 PM
• When you finish using the database object, click to close the object and return to the switchboard.
15
CREATE A BLANK DATABASE Product
ID
Company
Product
Unit Price
Quantity
If you want to design your own database, you can create a blank database. Creating a blank database gives you the most flexibility and control when designing a database.
You can have only one database open at a time. Access will close a database displayed on your screen when you create or open another database.
CREATE A BLANK DATABASE
Emily's Documents
Microsoft Access
⁄ Click to create a blank database. The New File task pane appears.
16
12:00 PM
¤ Click Blank Database to create a blank database.
Microsoft Access
The File New Database dialog box appears.
12:00 PM
‹ Type a name for your database.
Getting Started
Tip
1
What are the commonly used locations that I can access when saving a blank database?
nts
ocume
cent D
My Re
Provides access to databases and folders you recently worked with.
ts
cumen
p
Deskto
My Do
Allows you to store a database on the Windows desktop.
Provides a convenient place to store a database.
r
mpute
My Co
ces
work Pla
My Net
Allows you to store a database on a drive on your computer, such as a floppy or external hard drive.
Allows you to store a database on your network.
Emily's Documents
Create table in Design view
Microsoft Access
This area shows the location where Access will store your database. You can click this area to change the location.
12:00 PM
This area allows you to quickly access commonly used locations. To access a commonly used location, click the location.
› Click Create to create the database.
All Stars Sports Ltd : ...
Access creates a blank database.
12:00 PM
This area displays the name of the database.
The Database window appears. This window allows you to create and work with objects in your database, such as tables, queries and reports.
17
OPEN A DATABASE
You can open a database to view the database on your screen. Opening a database allows you to review and make changes to the database.
AD3 PUSH
SE
ABA DAT
E
S ABA DAT
RTS
REPO
S FORM RIES QUE LES TAB
COMPACT COMPACT
POWER
RESET
AD3
SE
ABA DAT
You can have only one database open at a time. Access will close a database displayed on your screen when you open another database. OPEN A DATABASE
12:00 PM
Microsoft Access
⁄ Click to open a database.
18
The Open dialog box appears.
Microsoft Access
This area shows the location of the displayed databases. You can click this area to change the location.
12:00 PM
This area allows you to access databases in commonly used locations. You can click a location to display the databases in the location. Note: For information on the commonly used locations, see the top of page 17.
Getting Started
Tip
1
How can I quickly open a database I recently used?
⁄ Click File. ¤ Click the name of
Access remembers the names of the last four databases you used. You can use the File menu to quickly open one of these databases.
the database you want to open. Note: If the names of the last four databases you worked with are not all displayed, position the mouse over the bottom of the menu to display all the names.
Outdoor Sporting Goods
Customers
12:00 PM
Microsoft Access
¤ Click the name of the database you want to open.
‹ Click Open to open the database.
Outdoor Sporting Go...
The database opens and appears on your screen. You can now review and make changes to the database.
12:00 PM
Note: A Security Warning dialog box may appear, asking you to confirm that you want to open the database. To open the database, click Open.
19
USING THE DATABASE WINDOW
You can use the Database window to open and work with objects in your database, such as tables, queries, forms, reports and pages.
ms
For es
i uer
Q
rts
po Re
ges
s ble
Pa
Ta
Create table in Design view
USING THE DATABASE WINDOW
Create table in Design view
Employees
All Stars Sports Ltd : ...
Each table, query, form, report and data access page in your database appears in the Database window.
20
12:00 PM
If the Database window is hidden behind other windows, press the F11 key to display the Database window.
All Stars Sports Ltd : ...
12:00 PM
This area displays the types of objects in your database.
This area displays all the objects of the type you selected.
⁄ Click the type of object
¤ To open an object,
you want to work with.
double-click the object.
Getting Started
Tip
1
What types of objects will I find in the Database window? Tables
Queries
Tables store information about a specific topic, such as a mailing list.
Queries allow you to find information of interest in your database.
Forms
Reports
Pages
Forms provide a quick way to view, enter and edit data in your database.
Reports summarize and print the data from your database in professional-looking documents.
Data access pages allow you to view, enter, edit and analyze data in your database from the Internet or your company's intranet.
Human Resources
Employees
All Stars Sports Ltd : ...
The object opens and appears on your screen.
Employees : Table
12:00 PM
‹ When you finish working with the object, click to close the object and return to the Database window.
12:00 PM
All Stars Sports Ltd : ...
CHANGE APPEARANCE OF OBJECTS
⁄ To change the appearance of the objects in the Database window, click one of the following buttons.
Large Icons Small Icons List Details
21
RENAME A DATABASE OBJECT
You can change the name of a database object, such as a table, form, query or report, to better describe the information stored in the object.
GLU E
Carter Cole Cook Grant
Alan Matt Jason
For information on renaming a data access page, see page 294.
RENAME A DATABASE OBJECT
Price List
Products
Tribute Electronics: ...
12:00 PM
Tribute Electronics: ...
⁄ In the Database window, click the type of database object you want to rename.
¤ Click the name of
› Type a new name
the object you want to rename.
for the object and then press the Enter key.
This area displays all the objects of the type you selected.
click the name again or press the F2 key. A black border appears around the name.
22
‹ After a few seconds,
12:00 PM
The object displays the new name.
DELETE A DATABASE OBJECT
Pro 0 State/ 1001 City 7 NY 0211 ss York Addre 0 . New MA 9411 Name ton Ave Last n 258 Lin Bosto 6 CA Name e ith 8911 isco First e Lan Schm Franc 50 Tre ss ID . San 6 NV Addre 3225 rson cker Ave s Pette 1 Jim 68 Cra s Vega 3 . La FL nda 3724 t sby Ave ille Talbo 2 Bre 47 Cro ksonv 5 TN s. Jac d 3037 old Cre e Dean 3 Tod vill 26 Arn Nash 8 GA uck son 0211 n Dr. Robin 4 Ch ta 401 Ido Atlan 0 MA lanie es 1002 ldon St. Hugh He 5 Me n 10 Bosto NY s St. san 921 zzard Toppin 6 Su York 36 Bu New CA ny zo Pl. go Kilken 15 Biz San Die son ple St. Marcu 890 Ap Martin
on 9 Jas Jim 10
eg 8 Gr
Posta vince l Code
se ba a t Da
1
en 7 All
If you no longer need a database object, such as a table, form, query or report, you can permanently delete the object from your database.
Getting Started
Before you delete an object, make sure other objects in your database do not depend on the object. For information on object dependencies, see page 124.
For information on deleting a data access page, see page 295.
DELETE A DATABASE OBJECT
Orders
12:00 PM
Tribute Electronics: ...
⁄ In the Database window, click the type of database object you want to delete.
¤ Click the name of
This area displays all the objects of the type you selected.
the object.
the object you want to delete.
‹ Click
to delete
Tribute Electronics: ...
A confirmation dialog box appears.
› Click Yes to
12:00 PM
The object disappears from the Database window.
permanently delete the object.
23
MINIMIZE A WINDOW
If you are not using a window, you can minimize the window to temporarily remove it from your screen. You can redisplay the window at any time.
Recycle Bin
Minimizing a window allows you to temporarily put a window aside so you can work on another task.
MINIMIZE A WINDOW
Order Details
Outdoor Sporting Go...
⁄ Click in the window you want to minimize.
Order Details : Table
12:00 PM
Outdoor Sporting Go...
The window reduces to a bar at the bottom of your screen. To once again show the contents of the window, click to restore the window to its original size.
24
Order Details : Table
12:00 PM
Note: You can also double-click a blank area on the bar to once again show the contents of the window.
DISPLAY OR HIDE A TOOLBAR
Getting Started
1
Access offers several toolbars that you can display or hide at any time. Each toolbar contains buttons that you can use to perform common tasks.
The available toolbars depend on the task you are performing. DISPLAY OR HIDE A TOOLBAR
Create table in Design view
sign view
12:00 PM
Outdoor Sporting Go...
⁄ Click View. ¤ Click Toolbars. A list of toolbars appears. A check mark ( ) beside the name of a toolbar indicates that the toolbar is currently displayed.
Note: The Task Pane also appears in the list of toolbars. Like a toolbar, the Task Pane allows you to perform common tasks.
Outdoor Sporting Go...
12:00 PM
Access displays or hides the toolbar you selected.
‹ Click the name of the toolbar you want to display or hide.
25
SEARCH FOR A DATABASE
If you cannot find a database you want to work with, you can search for the database. Spo
rts
Inc
.
SEARCH FOR A DATABASE
My Computer
12:00 PM
Microsoft Access
⁄ Click to search for a database. The Basic File Search task pane appears.
26
¤ Click this area and type all or part of the name of the database you want to find. Note: If the area already contains text, drag the mouse over the existing text before performing step 2.
Microsoft Access
‹ Click
in this area to select the locations you want to search.
A check mark (✔) appears beside each location that Access will search. Note: By default, Access will search all the drives and folders on your computer.
12:00 PM
› You can click the box beside a location to add ( ) or remove ( ) a check mark. ˇ Click outside the list of locations to close the list.
Getting Started
Tip
When selecting the locations I want to search, how can I display more locations?
Each location that displays a plus sign ( ) contains hidden locations. To display hidden locations, click the plus sign ( ) beside a location ( changes to ). To once again hide the locations, click the minus sign ( ) beside a location.
Tip
1
Can I view information about the databases that Access found?
Yes. To view information about a database that Access found, position the mouse over the database. A yellow box will appear, displaying the location of the database and the date you last made changes to the database.
My Computer
My Computer (3 of 3)
Access Files
12:00 PM
Microsoft Access
Á Click in this area to specify the types of files you want to search for.
‡ You can click the
A check mark (✔) appears beside each type of file that Access will search for.
° Click outside the list
box beside a file type to add ( ) or remove ( ) a check mark. of file types to close the list.
· Click Go to start the search.
12:00 PM
Microsoft Access
This area lists the databases with names that contain the text you specified.
‚ To close the task pane at any time, click .
To open a database in the list, click the database.
27
BACK UP A DATABASE
s onic lectr ute E -28 Trib 03-10
You can make a backup copy of your database. Regularly making a backup copy helps minimize any loss of information that may be caused by fire, computer viruses or the theft of your computer.
Making a backup copy of your database allows you to copy the information from your computer to a storage medium, such as a floppy disk, for safekeeping. BACK UP A DATABASE
le in Design view
Tribute Electronics_2003-10-28
Tribute Electronics : ...
⁄ Insert the disk that you want to back up your information on into a drive. ¤ Close all your open database objects. For information on closing a database object, see page 21.
28
12:00 PM
Microsoft Access
‹ Click File. › Click Back Up
The Save Backup As dialog box appears.
Database.
This area displays the name Access will use to save your backup copy of the database.
Note: If Back Up Database does not appear on the menu, position the mouse over the bottom of the menu to display the menu option.
12:00 PM
Note: To save the backup copy with a different name, drag the mouse over the existing name to highlight the name and then type the new name.
Getting Started
Tip
Can I store a backup copy of a database on a CD-R or CD-RW disc?
Tip
1
How can I restore my database using the backup copy?
If your database is lost or damaged, you can use the backup copy to restore the database to your computer.
You cannot back up your database directly to a CD-R or CD-RW disc. To store a backup copy of a database on a CD, perform the steps below to back up the database to a location on your computer. Then copy the backup file from your computer to a CD-R or CD-RW disc. For information on copying a file to a CD-R or CD-RW disc, see your Windows documentation.
Tribute Electronics_20 03-10-28
⁄ Insert the disk that contains the backup copy of the database you want to restore into a drive and display the contents of the disk.
¤ Drag the backup copy of the database onto your Windows desktop.
The backup copy of the database is now copied to your computer. You can rename and work with the backup copy as you would work with the original database.
Create table in Design view
Microsoft Access
This area shows the location where Access will store the backup copy of your database. You can click this area to change the location.
12:00 PM
ˇ Click Save to save the backup copy of your database.
Tribute Electronics : ...
Access saves the backup copy of the database in the selected location.
12:00 PM
When the backup is complete, Access redisplays the Database or Main Switchboard window for your original database. You can continue working with the database objects as you normally would.
29
GETTING HELP
If you do not know how to perform a task in Access, you can search for help information on the task. AD3
HSUP
Some help information is only available on the Internet. You must be connected to the Internet to access online help information. GETTING HELP
open a database
12:00 PM
Outdoor Sporting Go...
⁄ Click this area and type the task you want to get help information on. Then press the Enter key. The Search Results task pane appears.
This area displays a list of related help topics. You can use the scroll bar to browse through the available topics.
¤ Click the help topic of interest.
30
Outdoor Sporting Go...
A window appears, displaying information about the help topic you selected.
Microsoft Office Acce...
12:00 PM
‹ To display additional information for a word or phrase that appears in color, click the word or phrase.
Getting Started
Tip
What do the icons beside each help topic represent?
Here are some icons you will see beside help topics. Displays a help topic. Opens a Web page that takes you through step-by-step training for the task. Displays a pre-designed template, such as an inventory or expense report database.
Tip
1
How can I get help information when working with a dialog box?
You can click in the top right corner of a dialog box ( changes to ). Then click an area of the dialog box you want to view help information for. A box will appear, displaying help information for the area you selected.
Orders
Opens a Web page that offers a product or service to enhance Microsoft Office. Opens a Web page that displays an article on a specific topic.
Outdoor Sporting Go...
The additional information appears. Note: Selecting a colored word or phrase will display information such as a definition, tip or a list of steps.
Microsoft Office Acce...
12:00 PM
To once again hide the information, click the colored word or phrase.
Outdoor Sporting Go...
› When you finish reviewing the help information, click to close the window. To display the information for another help topic, click the help topic.
Microsoft Office Acce...
12:00 PM
ˇ When you are finished getting help, click to close the Search Results task pane.
31
HR100 2 PR555 ADV20 HR1
Employee # 5
ID
Robins
es
10
First Name
n
Hugh
nny
10 He
son
ince
ldon St
Posta
zzard
St.
l Code
zo Pl.
Address
City
State/Province Postal Code
. ple St
New
Boston
890 Ap
15 Biz
36 Bu
Martin
Marcu
Kilke
ins Topp
son 9 Ja Jim 10
eg 8 Gr
len 7 Al
sa 6 Su
ela 5 M
Last Name
ase b ta Da
York ego San Di
NY CA
1 Jim Address ID Schmith First Name 258 Linton Ave. New York Last Name Address City 10010 State/ProNY vince Postal Code 1 Jim 2 Brenda Petterson Schmith Tree 258 Lane Linton50Ave. YorkBostonNY PostalMA Code10010 02117 City NewState/Province Address Last Name First Name Address ID 3 Todd 2 Brenda PettersonTalbot 50 Tree Lane Address ID 68 Ave. San Francisco NY 258 Linton Ave. New YorkCracker Boston Schmith JimName Last 1 First Name MA10010CA Address 94110 State/Province Postal Code 02117 3 Todd4 Chuck Talbot Dean City 1 Jim 47Ave. Crosby 68 Cracker Las Vegas Address ID MA Boston LaneNew 50 TreeAve. SanAve. Petterson 258 Linton Brenda Schmith Francisco First2Name CA 02117NV 89116 Last York 94110 Name NY 10010 MelanieDean Robinson 4 Chuck5 Address City State/Pro vinceCres. 26Ave. Arnold 47 Crosby Code ille94110 CAPostal San Francisco Cracker Ave. 68 Lane Petterson 1 Jim2 Brenda Talbot 50 3 ToddSchmith Jacksonv Address ID Las Vegas Tree FL 89116 32256 First NV Name Boston Last Name New York Address 6258 Linton SusanAve.City 02117 NY MA Melanie Hughes State/Pro 3 4 Chuck 5 Talbot Robinson 401 Postal Dr. 10010 26 Arnold NV Vegas Lasvince Ave. Code 47 Crosby Nashville 1 Jim2 BrendaTodd Cres.Idon Jacksonv 68 Cracker TN ille FL 89116 Ave. SchmithPetterson Dean 37243 Francisco 50 258 Tree 32256 Linton Lane CA Ave. BostonSan NewState/Province Address 94110 York Allen MA Code NY Postal Address6 Susan7 City Name NameName Last Last ID ID FirstFirst Address Toppins Hughes 10010St.02117 4 Name Chuck 10 Heldon 401 Idon 32256 FL Atlanta Jacksonville 26 Arnold Cres. 5 Melanie Address 3 Todd Dean Robinson Dr. 2 Brenda Nashville 47 Crosby City GA 37243 30375 Talbot TN Petterson Ave. Las State/Pro vinceVegas Cracker 50 Tree Postal Ave.NY NV Lane San Francisco 1Jim Jim New68 258 Linton7Ave. Schmith Address ID 1 First 8 York CA Code GregBoston Allen MA 10010 Schmith 94110 89116 Name Kilkenny Toppins 02117 St. 5 Melanie 258 LintonRobinson Nashville Idon Dr.10 Heldon 401 Susan 6Address 36St.Buzzard Ave. Hughes New York26 4Name 3 Last Chuck Todd AtlantaTN BostonGA 37243 NYCres. Dean 68 City Arnold Talbot MA 30375 02118 10010 State/Pro Jacksonv 47 Crosby Cracker ille Ave.Francisco Postal Las Vegas MAvince Boston San Code 50 Tree Lane Petterson 1 2Jim2Brenda Brenda Schmith 32256 9 Ave. NV FL CA 02117 Jason Petterson Marcuso 6 258 Susan 30375 GA St.n Atlanta94110 89116 10 Heldon Tree8 Greg Toppins Kilkenny Allen 7 50 Linton Lane 15 Bizzo Ave. 36 Hughes Boston Pl. Buzzard New 5Address 4 Chuck York Melanie New St. York 401 Idon Boston MADr.Code10010 NY Postal City Last Name First Name Address ID NY 02118 10020 Nashville MA 02117 47State/Province Arnold Crosby 94110 TN San Cracker Ave. Talbot Dean68Robinson 3 3Todd Cres.CAJacksonv Ave. Las Todd 1026Francisco 2 Brenda Vegas 37243 ille Jim FL NV 9 Talbot Jason Petterson Address ID 89116St.32256 7 Ave. Cracker Marcuso 02118 MA 890 Apple 50Allen 36Martin Kilkenny Greg 8New68 Tree Ave.NYSan nBuzzard15St.BizzoBoston Lane Toppins 6 Linton Francisco 10010 York Boston 258 Schmith Susan Jim Name Last 1 First Pl. CA Name 5 Melanie 10 Heldon New YorkSan Diego CA MA Hughes St. 02117 Address Robinson Atlanta94110 NY 401Cres. Idon 26 Arnold Dr. NVNashville City Vegas Las Ave. 47 Crosby 4 4 Chuck 10020 92121 3 Todd Jacksonv Chuck TalbotDean 10State/Pro TN GA32256 3724330375 ille FL 89116 Jim vince Postal Dean 8 68Greg Code Martin Address ID 47Jason 10020 NY New 15 Bizzo Pl. Marcuson 9Boston Crosby Cracker Ave.Francisco 890 Apple Ave. San First 1Name 02117 MALas Lane Hughes 7 TreeAllen 50 Petterson6 258 2JimBrenda Vegas St. YorkSan Diego Kilkenny Susan Last NameSchmith NV St. 94110 Linton CA 36 Buzzard Ave. CA 10Dr.Heldon Boston89116 92121 32256 MA Jacksonville Cres.Idon ArnoldNY401 26Toppins Robinson Melanie 5 Address St. FLAtlanta City New York Nashville 10010 5 State/Pro 4 Chuck Melanie vince TN Postal Martin Dean68Robinson Code 92121 CA 02118 St. GASan Diego 890 Apple 10San 37243 30375 1 Jim 2 3Brenda 26Jim 9 Ave. 47Jason ArnoldLas Crosby 94110 CAJacksonv Francisco Talbot Todd Cres. Petterson Ave. Schmith 7Ave. 8 Cracker Marcuso Vegas Greg illeBizzo 50Allen 258 n NV Tree FLTN 89116 Lane 15 Toppins Kilkenny 32256 37243 York Boston Nashville Dr. IdonMA Susan 6 6 Linton 1010010 36St. Heldon York Buzzard NY 401 Code Postal State/Province City NewHughes Address Last Name First Name Address ID St. Pl. Atlanta BostonNew Susan 02117 5 Melanie GA MA NY30375 0211810020 Hughes 10 Ave. 2 Brenda 3 Todd 401Cres. Idon Jacksonv 26Jim Dr. 89116 Vegas Las 47 Arnold Dean 8Robinson Chuck Talbot 4 Petterson MartinNVNashville 9 Crosby 68Greg Jason Cracker TNGA ille 50 890 Apple Ave. San FL Lane St. 32256 Marcuso 37243 Kilkenny Francisco 10010 NY York New Boston 258 Linton Ave. 30375 CA San Diego Schmith 1 Jim Atlanta Heldon 10 Toppins Allen 7 Tree nSt.Buzzard CA36 15 Bizzo MA Pl. 7 St. 94110 New 6 Susan Allen Boston 02117 92121 York Toppins 401 3 Todd 4 Chuck 10Dr.HeldonNashville 02118 10020 32256 MA NY Jacksonville Melanie DeanRobinsonHughes 5 Talbot St. FLAtlanta 1026 Arnold Jim Cres.Idon 47 GA Crosby Jason TN Martin Ave. Las MA Boston San Francisco 50 Tree Lane688 Cracker Petterson 2 Brenda Marcuso Vegas02117 37243 30375 02118 MA Diego Boston 36 Buzzard St. Kilkenny Greg9Ave. St. York Bizzo890 San Pl. Apple 89116 7 Allen 8 Greg ToppinsKilkenny CA n NV1594110 New NY CA 4 Chuck 5 Melanie Nashville 401 Idon Dr. Hughes10 6 Susan Robinson 10020 92121 10 Heldon 36St. Buzzard St. TN Atlanta Boston GA 37243 26Jim 479Crosby Arnold MA NY CA Francisco San Ave. Talbot Dean68 Cracker 3 Todd Cres. Martin 94110 Ave. Jacksonv 10020 Las Vegas 15 Bizzo Pl. AppleNew Marcuson Jason 02118 St. York San Diego 30375 32256 9 Jason KilkennyMarcuso NV ille FL89089116 30375 CA Atlanta 92121 10 Heldon36 Toppins 7 Allen8 Greg 5 Melanie6 Susan nSt.Buzzard 15 Bizzo Hughes St. Pl. GA New Boston York 401 Idon 26 Dr. 89116 NV Vegas Las 47 Crosby Ave. Dean Robinson NY 92121 4 Chuck CA Diego San St. Apple 890 Martin JimCres. 10Arnold MA Jacksonv 02118 10020 TN 32256 illeNashville FL 10 Jim 37243 Martin 6 Susan 7 Allen 02118 MA Diego Boston 36n Buzzard KilkennyMarcuso 8 Greg9 Jason 15 St. St. York Toppins Bizzo890 San Pl. Apple New 401 CA 32256 FL Atlanta Jacksonville Cres.Idon RobinsonHughes26 Arnold 5 Melanie St. Dr. 10 Heldon Nashville 10020 92121 GA 37243 NY TN 30375 10 Martin 15 Bizzo890 10020 NY Pl. AppleNew 9 Jason Jim 7 Allen 8 Greg St. York KilkennyMarcuson San Diego 37243 TN Nashville Dr. Hughes Toppins401 Idon 6 Susan 10 36 Heldon CA Buzzard St. AtlantaSt. Boston 92121 GA MA 30375 CA 02118 92121 890 Apple St. San Diego Martin 10 Jim 9 Jason Marcuso Kilkenny10 Heldon 30375 7 Allen8 Greg Toppins n Atlanta 36St.Buzzard St.15 Bizzo Pl. GA New Boston York NY MA 10020 02118 10 Jim Martin 8 Greg9 Jason KilkennyMarcuso36n Buzzard 15 St. St.MA San Diego 02118 BizzoBoston Pl. 890 Apple New York CA 10020 NY 92121 10 Martin 15 Bizzo890 10020 NY Pl. AppleNew 9 Jason Jim Marcuson St. York San Diego CA 92121 92121 CA 890 Apple St. San Diego Martin 10 Jim
Address ID
921
Prov 0 State/ 1001 City 7 NY 0211 ess rk Addr w Yo 0 e. Ne e MA 9411 Nam ton Av Last 258 Lin e Boston 6 Nam ith 8911 co CA First e Lane ancis Schm 50 Tre San Fr ess ID 6 NV Ave. Addr 3225 rson acker gas Pette 1 Jim 68 Cr Las Ve 3 FL Ave. 3724 enda ille osby Talbot 2 Br 47 Cr cksonv 5 TN es. Ja dd 3037 nold Cr Dean 3 To ville 26 Ar Nash 8 GA on 0211 n Dr. 401 Ido lanta 0 . At MA 1002
uck 4 Ch
nie
tment urces Date Hired Depar n Reso Huma 12/2/90 Payroll ing s ti r e v 6/ urces Ad 1 n Reso Huma 3 2 sing Adver ti 11/25/95 3 s Payroll source an1R/9e5 4 Hu2m/2 yr3oll/97 P7a/1 5 g er ti3sin Ad5v/9 3/2 6 o r ll ay6 6/28P/9 7 8 11/12/9 8 8/16/89 9
A
Employee
s
CHAPTER 2
Create Tables Are you wondering how to create tables in your database? Learn how in this chapter. Create a Table in the Datasheet View ..............................34 Create a Table Using the Table Wizard ..........................................38
5 5552 33 ADV20 5 HR120
Open a Table ..................................42
30 ADV1o9urs/Wk H 0 PR557 9 40 HR300 2 3 R P 42 256
ng 6oll
2/98 6/89
Change a Column Width ..................43
5 ADV10 40 6 PR206
40 20 40 40 25 44 39
Rename a Field ................................44 Rearrange Fields ..............................45 Add a Field ......................................46 Delete a Field ..................................47 Change the Appearance of a Table ....48
s
Meal
Serving
4 e im T n o ti 1 Prepara Dinner s e t u st 6 25 min Breakfa Recipe ID s e t u e in m h m c a 4 15 Lun eN 1 s Recip n Stir-fry e t u in r e m n 2 45 Din Chicke 2 es t t u t le s in e fa m k m 4 O 45 Brea 3 Pizza s e t Veggie u in r 2 Dinne na 10 m 4 Lasag s e t u s in e k m Lunch Panca 30ops 5 s e h t C u in k st r Po 10nm Breakfa Salad es 6 e d r Ga 10 minut Dinner 7 s e t u in 30 m Dinner 8 s e t 15 minu 9 alad arden S
Table S E P I C E R
G
10
d
la Fruit Sa
First Nam e
CREATE A TABLE IN THE DATASHEET VIEW
You can create a table to store new information in your database.
City ss Addre
ame Last N ID
Julie
n Brow
or Taylr ris Mo
A table stores a collection of information about a specific topic, such as customer addresses or products.
k Mairane D
CREATE A TABLE IN THE DATASHEET VIEW
Field1 Create table by entering data
12:00 PM
Outdoor Sporting Go...
⁄ Click Tables in the Database window.
34
¤ Double-click Create table by entering data.
Outdoor Sporting Go...
Table1 : Table
12:00 PM
A blank table appears.
‹ To change a field name,
This area displays the field name for each field in your table.
double-click the field name to highlight the name.
Create Tables
Tip
What are the parts of a table?
Jack Erin Lisa Julie Alan Matt Jason Carl Simon Paul Sue Linda Frank
Adams Baker Bell Brown Carter Cole Cook Davis Evans Fraser Grant Harris Hill
Field
A field is a specific category of information and contains the same type of information for every record. For example, a field can contain the last name of every client.
Field Name
Record
A field name identifies the information in a field.
A record is a collection of information about one person, place or thing. For example, a record can contain a client's name and address.
Outdoor Sporting Go...
› Type a new field name and then press the Enter key.
2
Table1 : Table
12:00 PM
ˇ Repeat steps 3 and 4 for each field you want to include in your table.
Outdoor Sporting Go...
Table1 : Table
Á To enter the data for a record, click the first empty cell in the table. ‡ Type the data that corresponds to the field and then press the Enter key to move to the next field. Repeat this step until you finish entering all the data for the record.
12:00 PM
° Repeat steps 6 and 7 for each record you want to add to your table.
35
CREATE A TABLE IN THE DATASHEET VIEW
When creating a table, you can have Access create a primary key for the table.
Company ID Company Name
Address
City
State/Province Postal Code
1
Pet Superstore
258 Linton Ave. New York
NY
10010
2
Petterson Inc.
50 Tree Lane
MA
02117
3 Martin Vet Supplies 68 Cracker Ave. San Francisco CA
94110
4
Greg's Pet Store 47 Crosby Ave.
5
Pet Superstore
Boston Las Vegas
26 Arnold Cres. Jacksonville
NV
89116
FL
32256
6 Feline Foods Inc. 401 Idon Dr.
Nashville
TN
37243
7 Weasels R Us
Atlanta
GA
30375
Boston
MA
02118
10 Heldon St.
8 Purrrfect Portions 36 Buzzard St.
A primary key is one or more fields that uniquely identifies each record in a table, such as a field containing ID numbers. Each table in your database should have a primary key.
CREATE A TABLE IN THE DATASHEET VIEW (CONTINUED)
Outdoor Sporting Go...
· Click your table.
to save
The Save As dialog box appears.
Table1 : Table
‚ Type a descriptive name for your table.
— Click OK to save your table.
12:00 PM
Outdoor Sporting Go...
A dialog box appears, stating that your table does not have a primary key.
± To have Access create a primary key for you, click Yes.
36
Orders : Table
12:00 PM
Note: If you have entered information that uniquely identifies each record, such as ID numbers or part numbers, you can click No to create your own primary key. To create or change a primary key, see page 126.
Create Tables
Tip
Why should each table in my database have a primary key?
Tip
Access uses the primary key in each table to establish relationships between the tables in your database. Relationships between tables allow Access to bring together related information in the tables. For more information on relationships, see page 128.
Will Access analyze the information I enter in a table?
When you save a table, Access analyzes the information you have entered and assigns a data type to each field. A data type determines the kind of information you can enter in a field, such as text, numbers or dates. For more information on data types, see page 82.
ORDERS Table
ADDRESSES Table Company ID
2
Address
Company Name
City
Company ID
Zip Code
1
Pet Superstore
258 Linton Ave. New York
10010
1
2
Petterson Inc.
50 Tree Lane
02117
2
Boston
3 Martin Vet Supplies 68 Cracker Ave. San Francisco 94110 4
Greg's Pet Store 47 Crosby Ave.
5
Pet Superstore
Las Vegas
89116
Product
Product Number
Quantity Unit Price
Vitamins
C20595
2
$20.00
Bulk Dry Food
C28505
2
$18.00
3 Diet Dog Food
B29858
1
$10.00
4
5-Variety Biscuits
C33709
3
$3.50
5
Canned Dog Food
A40287
7
$1.50
6 Feline Foods Inc. 401 Idon Dr.
Nashville
37243
6
Diet Cat Food
F48851
2
$4.00
7 Weasels R Us
Atlanta
30375
7
Ferret Pellets
C58209
1
$6.50
Boston
02118
8 Dry Cat Food
G67483
3
$4.00
26 Arnold Cres. Jacksonville
10 Heldon St.
8 Purrrfect Portions 36 Buzzard St.
32256
NEW
Company Name Pet Superstore
Bulk Dry Food Diet Dog Food
Greg's Pet Store
5-Variety Biscuits
Pet Superstore
Canned Dog Food
Feline Foods Inc.
Outdoor Sporting Go...
Access removes the rows and columns that do not contain data. If you selected Yes in step 12, Access adds an ID field to your table to serve as the primary key. The ID field automatically numbers each record in your table.
Product Vitamins
Petterson Inc. Martin Vet Supplies
Diet Cat Food
Weasels R Us
Ferret Pellets
Purrrfect Portions
Dry Cat Food
Orders : Table
12:00 PM
Note: The numbers in the ID field may not begin at 1.
¡ When you finish reviewing your records, click to close your table.
Outdoor Sporting Go...
12:00 PM
The name of your table appears in the Database window.
37
CREATE A TABLE USING THE TABLE WIZARD
You can use the Table Wizard to quickly create a table. The wizard asks you a series of questions and then sets up a table based on your answers.
ARD
WIZ
? ? ? ?
The wizard can help you create a table for business or personal use. You can use the wizard to create tables that store information about specific topics, such as Customers, Products, Orders, Recipes and Investments. CREATE A TABLE USING THE TABLE WIZARD
CustomerID
Create table by using wizard
Customers
Outdoor Sporting Go...
⁄ Click Tables in the Database window.
12:00 PM
¤ Double-click Create table by using wizard.
The Table Wizard appears.
Outdoor Sporting Go...
‹ Click an option to specify whether the table is for business or personal use ( changes to ). › Click the sample table you want to use.
38
Note: The available sample tables depend on the option you selected in step 3.
12:00 PM
This area displays the available fields for the sample table you selected.
ˇ Double-click each field you want to include in the table. Note: To select all the fields at once, click .
Create Tables
Tip
2
What is a primary key?
A primary key is one or more fields that uniquely identifies each record in a table, such as a field containing ID numbers. Each table in your database should have a primary key. When using the Table Wizard to create a table, you can have Access set a primary key for you. Access will create a field that automatically numbers each record in your table. To later change the primary key, see page 126.
ID Number
First Name
1
Jack
2
Erin
Address
Last Name
City
Adams
York 258 Linton Ave. New
Baker
50 Tree Lane
Boston
Postal Code State/Province
NY MA
3
Lisa
Bell
San Francisco CA 68 Cracker Ave.
4
Julie
Brown
47 Crosby Ave.
Alan
Carter
26 Arnold Cres.
5 6
Matt
Cole
7
Jason
Cook
8
Carl
Davis
9
Simon
Evans
Paul
Fraser
10
Las Vegas
NV
Jacksonville
FL
401 Idon Dr.
Nashville
TN
10 Heldon St.
Atlanta
GA
Boston
MA
New York
NY
36 Buzzard St. 15 Bizzo Pl. 890 Apple St.
San Diego
CA
10010 02117 94110 89116 32256 37243 30375 02118 10020 92121
PostalCode
Customers PostalCode
Outdoor Sporting Go...
Outdoor Sporting Go...
12:00 PM
° Type a name for
‚ Click Next to continue.
the table.
You can click Back at any time to return to a previous step and change your selections.
Each field you select appears in this area.
Note: To remove all the fields you selected at once, click
Á To remove a field you
‡ When you finish
· To have Access set
accidentally selected, double-click the field in this area.
selecting all the fields you want to include in the table, click Next to continue.
a primary key for the table, click this option ( changes to ).
.
12:00 PM
Note: For information on the primary key, see the top of this page.
39
CREATE A TABLE USING THE TABLE WIZARD
The Table Wizard shows how your new table relates to the other tables in your database.
Payments ID 1 2 3 4 5 6 7 8 9 100
Deliveries Order ID 1 2 3 4 5 6 7 8 9 100
Customer Fred's Appliances Home Center Kitchen Supplies Appliance Warehouse Wilmington's Kitchen Depot Kitchen and Bath Inc. Bob's Kitchen Center Basin Bubbles Ceramic World
City Chic Chicago Los Angeles St. LLouis New York New York Miami Mia Detroit Detr Buffalo Buff Dallas Dall New York
Shipping Method Truck Air Truck Train Train Air Truck Truck Air Train
Customer Fred's Appliances Home Center Kitchen Supplies Appliance Warehouse Wilmington's Kitchen Depot Kitchen and Bath Inc. Bob's Kitchen Center Basin Bubbles Ceramic World
Account # Payment Received Ac 4/3/99 83625 4/6/99 23557 4/11/99 87782 4/15/99 98711 4/18/99 66212 4/22/99 81511 4/23/99 15415 4/24/99 89715 4/25/99 61541 4/26/99 90715
Order Details Order ID 1 2 3 4 5 6 7 8 9 10
Customer Fred's Appliances Home Center Kitchen Supplies Appliance Warehouse Wilmington's Kitchen Depot Kitchen and Bath Inc. Bob's Kitchen Center Basin Bubbles Ceramic World
Product Dish Dishwasher Dining Table Dini Stove Stov Microwave Mic Fridge Frid Kitchen Chair Kitc Sink Toaster Oven Toas Shower Unit Sho Floor Tiles Floo
Quantity 6 8 10 5 6 17 11 23 9 300
Relationships between tables allow Access to bring together related information in the tables. For more information on relationships, see page 128. CREATE A TABLE USING THE TABLE WIZARD (CONTINUED)
not related to 'Order Details'
Outdoor Sporting Go...
12:00 PM
This screen appears if other tables exist in your database.
This area displays how the new table relates to the existing tables.
Note: If this screen does not appear, skip to step 12.
— Click Next to continue.
40
Outdoor Sporting Go...
± Click this option to be able to enter data directly into the table after the wizard finishes creating the table ( changes to ).
12:00 PM
¡ Click Finish to create the table.
Create Tables
Tip
Can I make changes to a table?
Tip
Yes. After you create a table using the Table Wizard, you can make changes to the table. For example, you can change the width of columns, rename a field, rearrange fields, add a new field or delete a field. To make changes to a table, see pages 43 to 49.
ss
Addre
City
StateIN City dianapolis Bill In ss Bil. l AddreSpencer Ave CT
14 Name Roger hartford Last H Bill ill ame t. Roger l First N Elm S CA il k 5 B n 8 ra o F ieg r San D MD Roger Bill Frase ore ne St. r im ra e lt C g a IL l o 5 B u 2 R 1 Pa t. S rt o in a r AR Freep Roger Taylo 772 M k c t. o S R e e r Littl Mark 14 Pin Turne ge St. e ll o n C o 192 Kevin Wils Mary White b Bo
State
e
Customers: Table
Can I later add records to a table?
After you create a table, you can add new records to the table at any time. For example, you may want to add information about a new customer to a table containing customer information. To add new records to a table, see page 64.
am First N
Outdoor Sporting Go...
2
12:00 PM
This area displays the field names for the table.
Note: The numbers in the ID field may not begin at 1.
If you selected Yes in step 9, Access adds an ID field to the table to serve as the primary key. The ID field will automatically number each record you add to the table.
™ To enter the data for a record, click the first empty cell in the table.
Outdoor Sporting Go...
£ Type the data that corresponds to the field and then press the Enter key to move to the next field. Repeat this step until you finish entering all the data for the record.
Customers: Table
12:00 PM
¢ Repeat steps 14 and 15 for each record you want to add to your table. Access automatically saves each record you enter.
∞ When you finish entering records, click the table.
to close
41
OPEN A TABLE Name Recipe ID Recipe
Meal
r 1 Chicken Stir-fry Dinne Breakfast 2 Omelet Lunch 3 Veggie Pizza Dinner 4 Lasagna Breakfast 5 Pancakes Dinner 6 Pork Chops 7 Garden Salad Lunch Breakfast 8 Fruit Salad
You can open a table to display its contents on your screen. Opening a table allows you to review and make changes to the table.
Vegetarian No Yes Yes No Yes No Yes Yes
250mL
150mL 50mL
PUSH
COMPACT COMPACT
R POWE
RESET
OPEN A TABLE
American Outdoors
Customers
12:00 PM
Outdoor Sporting Go...
⁄ Click Tables in the Database window.
This area displays a list of the tables in your database.
The table opens. You can now review and make changes to the table.
¤ Double-click the
When you finish working with the table, click to close the table.
table you want to open.
42
Outdoor Sporting Go...
Customers : Table
12:00 PM
Note: A dialog box will appear if you did not save changes you made to the layout of the table. To specify if you want to save the changes, click Yes or No.
CHANGE A COLUMN WIDTH
You can change the width of a column in a table. Increasing the width of a column allows you to view data that is too long to display in the column.
Carl Simon Paul Sue Linda Frank David Nancy
Create Tables
Davis Evans Fraser Grant Harris Hill Jones King
2
Reducing the width of columns allows you to display more fields on your screen at once.
CHANGE A COLUMN WIDTH
Tribute Electronics : ...
⁄ To change the width of a column, position the mouse over the right edge of the column heading ( changes to ).
Order Details : Table
12:00 PM
¤ Drag the column edge until the line displays the column width you want.
Tribute Electronics : ...
The column displays the new width.
‹ Click
to save your change.
Order Details : Table
12:00 PM
FIT LONGEST ITEM
⁄ To change a column width to fit the longest item in the column, double-click the right edge of the column heading. 43
RENAME A FIELD
You can give a field a new name to more accurately describe the contents of the field.
Preparation Time
RECIPES Table Recipe ID
Recipe Name
tir-fry 1 Chicken S 2 Omelet ie Pizza 3 Vegg sagna 4 La P ncakes
Time
Meal
Servings
4 Dinner s te u 1 25 min reakfast B s te 6 15 minu nch u L s 4 45 minute inner D s 2 45 minute akfast re B 4 10 minutes Dinner
2
RENAME A FIELD
Section Linda Frank David Nancy Stacy Ann Amy Sara Diane Josh Daniel Helen Emily Ryan Mark
Tribute Electronics : ...
⁄ Double-click the field name you want to change.
44
Harris Hill Jones King Lee Lewis Martin Miller Morris Nelson Price Reed Ross Smith Taylor
Employees : Table
The field name is highlighted.
1
12:00 PM
Tribute Electronics : ...
¤ Type a new name for the field and then press the Enter key.
Linda Frank David Nancy Stacy Ann Amy Sara Diane Josh Daniel Helen Emily Ryan Mark
Harris Hill Jones King Lee Lewis Martin Miller Morris Nelson Price Reed Ross Smith Taylor
Employees : Table
The field displays the new name.
12:00 PM
REARRANGE FIELDS
You can change the order of fields to better organize the information in a table.
Create Tables
2
Employee # 5
HR100 2 PR555 33 ADV20 5 HR120
30 ADV1o9urs/Wk H 0 PR557 t n e 9 40 tm s HR300 Depar source Date Hired e 2 R n PR342 25 Huma 56 ADV10 40 12/2/90 Payroll 2066 R g P in is 40 6/ urces Advert 1 n Reso Huma 3 20 g in 2 is Advert 11/25/95 40 ll 3 ro s y e a rc P 1R/9e5sou n 40 /2 2 a m u 4 H ll 7 3/9 25 yro P7a/1 5 g ert3isin d5v/9 /2 44 A 3 6 ay6roll 39 6/28P/9 7 1/12/98 1 8 8/16/89 9
s
Employee ID
Rearranging fields in the Datasheet view will not affect how the fields appear in the Design view of a table. For information on the views of a table, see page 74.
10
REARRANGE FIELDS
Department
Department Sales Marketing Human Resources Sales Sales Human Resources Marketing Sales Marketing Accounting Sales Sales Production Production Marketing
Tribute Electronics : ...
⁄ Click the name of the field you want to move. The field is highlighted.
Linda Frank David Nancy Stacy Ann Amy Sara Diane Josh Daniel Helen Emily Ryan Mark
Harris Hill Jones King Lee Lewis Martin Miller Morris Nelson Price Reed Ross Smith Taylor
Employees : Table
Linda Frank David Nancy Stacy Ann Amy Sara Diane Josh Daniel Helen Emily Ryan Mark
12:00 PM
¤ Position the mouse over the field name and then drag the field to a new location.
Harris Hill Jones King Lee Lewis Martin Miller Morris Nelson Price Reed Ross Smith Taylor
Tribute Electronics : ...
The field appears in the new location.
Sales Marketing Human Resources Sales Sales Human Resources Marketing Sales Marketing Accounting Sales Sales Production Production Marketing
Employees : Table
‹ Click
12:00 PM
to save your
change.
A thick line shows where the field will appear.
45
ADD A FIELD
You can add a field to a table when you want the table to include an additional category of information.
A field is a specific category of information in a table, such as the phone numbers of all your clients. ADD A FIELD
Billing Address 900 Turling Ave. 1300 Kennedy Dr. 336 Bay St. 14 Spencer Ave. 6858 King St. 55 Sunset St. 670 Pine Dr. 88 Lincoln Blvd. 255 Park Dr. 456 Harding Blvd. 36 College Rd.
Outdoor Spor...
⁄ Click the name of the field you want to appear after the new field. The field is highlighted.
46
12:00 PM
Customers : T...
¤ Click Insert. ‹ Click Column.
Outdoor Spor...
Customers : T...
The new field appears in your table.
12:00 PM
Access assigns a name to the new field. To give the field a descriptive name, see page 44 to rename the field.
DELETE A FIELD
Create Tables
2
s
If you no longer need a field, you can permanently delete the field from a table.
Meal
Serving
4 1 Prepara Dinner tes st 6 25 minu Breakfa Recipe ID s e inute 4 Lunch e Nam y 15 m 1 ip c e fr R tes n Stir2 45 minu Dinner Chicke 2 tes t st 4 Omele 45 minu Breakfa 3 Pizza ie g s g Ve inute 2 Dinner na 10 m g 4 a s a L kes minutes 2 Lunch Panca 30ops 5 h inutes st 7 Pork C 10 m Breakfa Salad 6 n e s rd Ga 10 minute 8 inner D 7 s 0 minute r 3 e n in D 8 tes 15 minu 9 alad arden S
RECIPES
Before you delete a field, make sure the field is not used in any other objects in your database, such as a form, query or report.
Table
e tion Tim
G
d
la Fruit Sa in lo Sir
10
ork Roast P
You cannot delete a field used to create a relationship to another table in the database. For information on relationships, see page 128. DELETE A FIELD
Field1
Field1
Outdoor Spor...
⁄ Click the name of the field you want to delete. The field is highlighted.
Customers : T...
12:00 PM
¤ Click Edit. ‹ Click Delete Column.
Outdoor Spor...
Customers : T...
A confirmation dialog box appears.
12:00 PM
The field disappears from your table.
› Click Yes to permanently delete the field.
47
CHANGE THE APPEARANCE OF A TABLE
You can change the cell style and colors in a table to enhance the appearance of the table.
CHANGE THE APPEARANCE OF A TABLE
Yellow
Tribute Electronics : ...
⁄ Click Format. ¤ Click Datasheet.
Orders : Table
The Datasheet Formatting dialog box appears.
12:00 PM
Tribute Electronics : ...
Orders : Table
‹ Click the cell effect you want to use ( to ).
changes
Note: If you selected Raised or Sunken in step 3, skip to step 9.
48
› To remove the horizontal or vertical gridlines, click each gridline you want to remove ( changes to ).
12:00 PM
ˇ To change the background color, click this area to display a list of the available colors. Á Click the background color you want to use.
Create Tables
Tip
How can I change the border or line styles in a table?
In the Datasheet Formatting dialog box, you can change the border and line styles in a table.
Tip
Can I change the appearance of a form or query?
You can also perform the steps shown below to change the appearance of a form or a query displayed in the Datasheet view. To change the view of a form or query, see page 152 or 202.
Form
Datasheet Border
Solid
You can click this area to select the type of border or line you want to change.
2
Query
Customer
City
State
Paul Fraser Ryan Smith
Albany Sacramento
NY CA
Daniel Price Stacy Lee
Miami San Francisco
FL CA
Frank Hill Carl Davis
Los Angeles Springfield
CA IL
Alan Carter David Jones
New York San Diego
NY CA
?
Which clients live in California? City
State
Ryan Smith
Sacramento
CA
Stacy Lee
San Francisco
CA
Frank Hill
Los Angeles
CA
David Jones
San Diego
CA
Customer
You can click this area to select a style for the type of border or line you selected.
Blue
Tribute Electronics : ...
‡ To change the gridline color, click this area to display a list of the available colors. ° Click the gridline color you want to use.
Orders : Table
12:00 PM
This area displays a preview of how your table will appear.
Tribute Electronics : ...
The table displays the changes you selected.
Orders : Table
‚ Click
12:00 PM
to save your
changes.
· Click OK to apply your changes to the table.
49
Book ID
T
S ihsecap sE rf epac H H s’hgu itS etaW ll ehT T o u r i s ehT C o w b o yM C l a n d e s hT e M a g i ac
1 2 3 4 5 6 7 8
Title Spaceships in Orbit Escape from Reality Hugh's Haunted Castle Still Waters Run Deep The Tourist The Cowboy Invasion My Clandestine Ways The Magical Lilac Tree
Customers
19 19 19 19 19 19 20 19
CHAPTER 3
Edit Tables Do you want to work with and edit the data in your tables? This chapter teaches you how to add and remove records, hide and freeze fields in your tables and more.
1988 1990 1984 1996 1999 1993 2001 1997
Move Through Data ..........................52 Select Data ......................................54 Edit Data ..........................................56 Zoom Into a Cell ..............................58 Display a Subdatasheet......................59 Check Spelling..................................60 Move or Copy Data ..........................62 Add a Record ..................................64 Delete a Record ................................65
ORDERS Table Company Name
Order ID
Product
Quantity
Unit Price
1
Pet Superstore
Vitamins
12
$20.00
2
Petterson Inc.
3
Martin Vet Supplies
4
Greg’s Pet Store
Bulk Dry Food
15
$18.00
Diet Dog Food
30
$10.00
5-Variety Biscuits
50
$3.50
5
Pet Superstore
6
Feline Foods Inc.
Dry Cat Food
7
Weasels R Us
Canned Dog Food Ferret Pellets
24
$3.00
40
$4.00
30
8
Purrrfect Portions
Dry Cat Food
24
$6.50 $4.00
9
Doggone Yummy Inc.
Steak-flavored Bones
40
$1.25
10 11
Jim’s Pets Allen’s Dog Kennel
Hamster Treats Puppy Kibble
30 20
$5.00 $8.50
12
B&T Food Suppliers
Gerbil Mix
35
$4.50
13
Pet Superstore
Parrot Food
25
$17.00
14
Kitty-Mart
Dry Cat Food
35
$4.00
15
Canine Nutrition Inc.
Rawhide Chew Sticks
15
$2.00
Change the Font of Data ....................66 Hide a Field ....................................68 Freeze a Field ..................................70
MOVE THROUGH DATA
You can move through the data in a table to review and edit information.
Test 1 (60)
Student ID 960001
Test 2 (40) 50
25 30
56
960002
35 45
960003
54
960004
960005
If a table contains a lot of data, your computer screen may not be able to display all the data at once. You can scroll through records and fields to display data that does not appear on your screen.
22 38 42
29 40
960006
MOVE THROUGH DATA
Outdoor Sporting Go...
MOVE THROUGH RECORDS
⁄ Click any cell in the record you want to make the current record.
Products : Table
12:00 PM
An arrow ( ) appears beside the current record. This area displays the number of the current record and the total number of records in the table.
Outdoor Sporting Go...
¤ To move through the records, click one of the following buttons. First record Previous record Next record Last record
52
Products : Table
12:00 PM
To quickly move to a specific record, double-click this area and then type the number of the record you want to display. Then press the Enter key.
Edit Tables
Tip
3
How do I use my keyboard to move through data in a table?
To Move:
Press on Keyboard:
Up one screen of records
Page Up
Down one screen of records
Page Down
To the next field in the current record
Tab
Up one record in the same field Down one record in the same field
Outdoor Sporting Go...
SCROLL THROUGH RECORDS
⁄ To scroll one record at a time, click
or
.
Note: You cannot scroll through records if all the records appear on your screen.
Products : Table
12:00 PM
To quickly scroll to any record, drag the scroll box along the scroll bar until a yellow box displays the number of the record you want to view.
Outdoor Sporting Go...
SCROLL THROUGH FIELDS
⁄ To scroll one field at a time, click
or
.
Note: You cannot scroll through fields if all the fields appear on your screen.
Products : Table
12:00 PM
To quickly scroll to any field, drag the scroll box along the scroll bar until the field you want to view appears.
53
SELECT DATA
Before performing many tasks in a table, you must select the data you want to work with. Selected data appears highlighted on your screen.
3 Jack's Restaurant St. Paul
Table decorations
1/12/2004
CA 3 Jack's Restaurant TableAve. decorations San Francisco1/12/2004 TalbotSt. Paul 68 Cracker 3 Todd
AD3
PUSH
SELECT DATA
Employee ID 512 518 524 535 511 538 512 511 524 511 512 511 535 512
Tribute Electronics : ...
SELECT A FIELD
⁄ Position the mouse over the name of the field you want to select ( changes to ) and then click to select the field.
54
Order Details : Table
5 Park Radio
12:00 PM
To select multiple fields, position the mouse over the name of the first field ( changes to ). Then drag the mouse until you highlight all the fields you want to select.
Tribute Electronics : ...
SELECT A RECORD
⁄ Position the mouse over the area to the left of the record you want to select ( changes to ) and then click to select the record.
1/25/2002
Order Details : Table
511 Cellular Phone
12:00 PM
To select multiple records, position the mouse over the area to the left of the first record ( changes to ). Then drag the mouse until you highlight all the records you want to select.
Edit Tables
How do I select all the information in a table?
Tip
1 2 3 4 5 6 7 8 9 10 11 12 13 14
Emerald Creek Electronics Home Electronics Depot Radio City Stereos and More! Park Radio Henry's Electronic Store Barbara's Video Palace CC&M Radio Store Radio City Stereos and More! Barbara's Video Palace Radio City Emerald Creek Electronics Radio City
1/12/2002 2/3/2002 12/3/2001 12/8/2001 1/25/2002 2/18/2002 2/23/2002 12/10/2001 2/28/2002 1/4/2002 12/13/2001 1/8/2002 12/8/2001 12/15/2001
512 518 524 535 511 538 512 511 524 511 512 511 535 512
Tip
3
How do I deselect data?
DVD Player Mini Speakers 3-Disc CD Cha 32" Television Cellular Phon Mini Speakers 4-head Hi-Fi V Digital Video R Stereo Headp Digital Camer DVD Player Digital Video R Digital Camer DVD Player
To deselect data, click anywhere in the table.
To select all the information in a table, click the blank area ( ) to the left of the field names.
Digital 1/4/2002
Tribute Electronics : ...
SELECT A CELL
⁄ Position the mouse over the left edge of the cell you want to select ( changes to ) and then click to select the cell.
Order Details : Table
12:00 PM
To select multiple cells, position the mouse over the left edge of the first cell ( changes to ). Then drag the mouse until you highlight all the cells you want to select.
Tribute Electronics : ...
SELECT DATA IN A CELL
⁄ Position the mouse over the left edge of the data and then drag the mouse until you highlight all the data you want to select.
Order Details : Table
12:00 PM
To quickly select a word, double-click the word.
55
EDIT DATA
You can edit the data in a table to correct a mistake or update the data.
1 Chicken Stirfry Dinner 2 Omelet Br eakfast 3 Veggie Pizz a un ch 4 Lasagna Di nn er 5 Pancakes Breakfast 6 Pork Chops D inner 7 Garden Sala d Lunch 8 Fruit Sala d Breakfast
No Yes Yes No Yes No Yes Yes
Access automatically saves the changes you make to the data in a table.
EDIT DATA
East
All Star Sports Ltd : D...
INSERT DATA
⁄ Click the location in the cell where you want to insert data. A flashing insertion point appears in the cell, indicating where the data you type will appear.
56
Customers : Table
12:00 PM
Note: You can press the or key to move the insertion point.
¤ Type the data you want to insert.
All Star Sports Ltd : D...
DELETE DATA
⁄ Drag the mouse over the data you want to delete to highlight the data.
¤ Press the
Delete key to delete the highlighted data.
Customers : Table
12:00 PM
Note: To delete a single character, click the location where you want to delete the character. To remove the character to the left of the insertion point, press the Backspace key. To remove the character to the right of the insertion point, press the Delete key.
Edit Tables
Tip
What are the symbols that appear to the left of the records in a table?
Tip
3
Why can't I edit the data in a cell?
You may be trying to edit data in a field that has the AutoNumber data type. A field that has the AutoNumber data type automatically numbers each record for you to uniquely identify each record. For more information on data types, see page 83.
This is the current record.
You are editing this record.
1 2 3
Chicken Stir
Omelet Veggie Pizza 4 Lasagna 5 Panc akes 6 Pork Chops 7 G
You can enter data for a new record here.
22 Whittle St.
All Star Sports Ltd : D...
REPLACE ALL DATA IN A CELL
⁄ Position the mouse over the left edge of the cell containing the data you want to replace with new data ( changes to ) and then click to select the cell.
Customers : Table
12:00 PM
The cell is highlighted.
All Star Sports Ltd : D...
Customers : Table
¤ Type the new data
UNDO CHANGES
and then press the Enter key.
⁄ Click
12:00 PM
to immediately undo your most recent change.
57
ZOOM INTO A CELL
You can zoom into any cell in a table to make the contents of the cell easier to review and edit.
Although Brian is a relatively new customer, he has placed many orders with us over the past few months. He has commented many times on how nice it is to order from us. He says our customer service is excellent! Brian has signed up for our preferred customer plan, which entitles him to special offers at our store.
City Address Green Bay es . ot ve N A hittle ord st Name Cu 220 W lvd. Hartf apolis Name La Long term ilverton B ID First Indian Reed me 190 M ncer Ave. m co re Has Spe 1 Helen San Diego out 14 Evans Makes ab Crane St. 2 Simon Baltimore me 125 o Baker st t. u S C n Mai New 2 Freeport 77 3 Erin nt in Gra k Purchases n i 24 Pine St. Little Roc 4 Sue o t. Smith Depends Bria 192 College S 5 Ryan h Cook Althoug 6 Jason White an ri B 7
Zooming into a cell is useful when a cell contains a large amount of information, such as notes about a customer.
ZOOM INTO A CELL
Linda Frank David Nancy Stacy Ann Amy Sara Diane Josh Daniel Helen Emily Ryan
Tribute Electronic...
⁄ Click the cell you want to zoom into.
58
Harris Hill Jones King Lee Lewis Martin Miller Morris Nelson Price Reed Ross Smith
Employees : Table
¤ Press and hold down the Shift key as you press the F2 key.
12:00 PM
Tribute Electronics...
The Zoom dialog box appears. This area displays all the data in the cell. You can review and edit the data. To edit data, see page 56.
Employees : Table
12:00 PM
‹ When you finish reviewing and editing the data, click OK to close the dialog box. The table will display any changes you made to the data.
DISPLAY A SUBDATASHEET
When viewing the information in a table, you may be able to display a subdatasheet to view and edit related data from another table.
Edit Tables
3
Customers : Table City ID Company Name Billing Address 123 Bell Lane Seattle 1 Sports Inc. Chicago 2 Racquets & Stuff 456 Tree Blvd.
3 4
For example, when viewing a table containing customer information, you can display a subdatasheet to view the orders placed by a customer.
Orders : Table Unit Price Discount Product ID Quantity 10% 10 $458.70 45680 15% 20 $622.90 74238 35 Pine St. Baltimore Outside36749 Fun 15% 37 $714.03
Born to Be Wild 991 Sunset Dr.
You can display a subdatasheet only when a table is related to another table. For information on relationships, see page 128.
Tampa
DISPLAY A SUBDATASHEET
Outdoor Sporting Go...
When information in a table relates to data in another table, a plus sign ( ) appears beside each record.
Customers: Table
12:00 PM
⁄ To display related data from the other table, click the plus sign ( ) beside a record ( changes to ).
Outdoor Sporting Go...
Customers: Table
A subdatasheet appears, displaying the related data from the other table. You can review and edit the data. To edit data, see page 56.
12:00 PM
¤ To once again hide the subdatasheet, click the minus sign ( ) beside the record.
59
CHECK SPELLING
You can find and correct all the spelling errors in a table.
Book ID
Title
Year Published Pages
1 Spaceships in Orbit
1988
360
2 Escape from Reality
1990
400
3 Hugh’s Haunted Castle
1994
315
4 Still Waters Run Deep
1996
375
5 The Tourist
1989
545
6 The Cowboy Invasion
1993
250
7 My Clandestine Ways
1991
325
8 The Magical Lilac Tree
1987
425
Access compares every word in your table to words in its dictionary. If a word in your table does not exist in the dictionary, Access considers the word misspelled. CHECK SPELLING
Seakers
Seakers
Seekers
Tribute Electronic...
⁄ To spell check your entire table, click any cell in the table.
Note: To spell check only part of your table, select the field, record or cell you want to check in the table. To select data in a table, see page 54.
¤ Click spell check.
60
12:00 PM
Order Details : Ta...
to start the
Tribute Electronic...
The Spelling dialog box appears if Access finds a misspelled word in your table. This area displays the misspelled word.
Order Details : Ta...
12:00 PM
This area displays suggestions for correcting the word.
Edit Tables
Tip
Can Access automatically correct my typing mistakes?
Tip
Yes. Access automatically corrects common spelling errors as you type. Here are a few examples:
adn alot comittee don;t nwe occurence recieve seperate teh
3
Will a spell check find all the errors in my table?
No. A spell check will find only spelling errors. Access will not find correctly spelled words used in the wrong context, such as "blew" in a Product Color field. You should carefully review your table to find this type of error.
and a lot committee don't new occurrence receive separate the
duct
Product Color
ater
beige
oves
blew
ots ts
Quantit
brown dark blue white yellow
Seakers
Speakers
Tribute Electronic...
‹ Click the suggestion you want to use to correct the word.
› Click Change to correct the word in your table.
Order Details : Ta...
12:00 PM
To skip the word and continue checking your table, click Ignore. Note: To skip the word and all other occurrences of the word in your table, click Ignore All.
Tribute Electronics ...
ˇ Correct or ignore misspelled words until this dialog box appears, telling you the spell check is complete.
Order Details : Table
12:00 PM
Á Click OK to close the dialog box.
61
MOVE OR COPY DATA
You can move or copy data to a new location in your table.
Moving data allows you to rearrange data in your table. When you move data, the data disappears from its original location. Copying data allows you to repeat data in your table without having to retype the data. When you copy data, the data appears in both the original and new locations. MOVE OR COPY DATA
Fishing
Outdoor Sporting Go...
⁄ To move or copy data in a cell, drag the mouse over the data until you highlight the data you want to move or copy.
62
Order Details : Table
12:00 PM
To copy the entire contents of one or more cells, select the cell(s) containing the data you want to copy. To select cells, see page 55.
Outdoor Sporting Go...
¤ Click one of the following buttons. Move data Copy data
Order Details : Table
12:00 PM
‹ Click the location in the table where you want to place the data. If you copied the entire contents of one or more cells, select the cell(s) where you want to place the data.
Edit Tables
Tip
3
Why does the Clipboard task pane appear when I move or copy data?
When you move or copy data, the Clipboard task pane may appear. The Clipboard task pane displays the last items you have selected to move or copy. To place a clipboard item in your table, click the location where you want to place the item and then click the item in the task pane.
$189.99
DVD Player
Video Domain
Note: To close the Clipboard task pane, click at the top of the task pane.
Fishing Lure
Outdoor Sporting Go...
› Click
to place the data in the new location.
Order Details : Table
The data appears in the new location.
12:00 PM
Outdoor Sporting Go...
Order Details : Table
12:00 PM
COPY DATA DOWN ONE CELL
¤ Press and hold down
⁄ Click the cell directly
the Ctrl key as you press the ' (apostrophe) key.
below the data you want to copy.
Access copies the data to the cell.
63
ADD A RECORD
You can add a new record to include additional information in your table. For example, you may want to add information about a new customer.
Customers
You can add a new record only to the end of your table. If you later want to change the order of the records in the table, you can sort the records. To sort records, see page 176. ADD A RECORD
Simon Paul Sue Linda Frank David Nancy Stacy Ann Amy Sara Diane Josh Daniel
Wayne Count...
⁄ Click to add a new record to your table.
64
Paul Sue Linda Frank David Nancy Stacy Ann Amy Sara Diane Josh Daniel Helen
Evans Fraser Grant Harris Hill Jones King Lee Lewis Martin Miller Morris Nelson Price
Membership : ...
12:00 PM
¤ Click the first empty cell in the row.
Wayne Count...
Fraser Grant Harris Hill Jones King Lee Lewis Martin Miller Morris Nelson Price Reed
Membership : ...
‹ Type the data that corresponds to the field and then press the Enter key to move to the next field.
12:00 PM
› Repeat step 3 until you finish entering all the data for the record. Access automatically saves each new record you add to the table.
DELETE A RECORD
You can delete a record from a table to permanently remove information you no longer need. For example, you may want to remove information about a customer who no longer orders your products.
Cat Food
Cat Food
Edit Tables
Dry Cat Food
Dry Cat Food
Customer Name e Pet Superstor Petterson Inc. lies Martin Vet Supp
Dry Cat Food
Dry Cat Food
Address 22 Whittle St.
Dry Cat Food
Dry Cat Food
City
Deleting records saves storage space on your computer and keeps your database from becoming cluttered with unnecessary information.
Dry Cat Food
State Zip Code
Cat Food
WI
Green Bay CT Hartford IN s oli ap ian Ind San Diego CA
et 190 Main Stre e. 14 Spencer Av e St. an Cr 5 12 e Greg's Pet Stor Baltimore et 104 Main Stre . Feline Foods Inc Frreee F eppo orrt 24 Pine St. tI Rock L tle Cats R Us Lit . Rd 192 College ns rtio Po te t lot fec Char Purrr e. Av e ov Gr 65 Elm Tampa Pets 'n' More . 24 Cortez Blvd . Inc y mm Syracuse Doggone Yu 55 Sunset St. Jim's Pets
Dry Cat Food
MD
54324 06199 46290 92199
Dry Cat Food
21297
3
Cat Food
72295 AR 61032 28299 NC 33697 FL 13290 NY
Dry Cat Food
When you delete a record, you may also want to delete any related records in other tables. For example, if you delete a company from your supplier table, you may also want to delete the company's products from your products table.
Cat Food
DELETE A RECORD
Simon Paul 3 Sue Linda Frank David Nancy Stacy Ann Amy Sara Diane Josh Daniel
Evans Fraser Grant Grant Harris Hill Jones King Lee Lewis Martin Miller Morris Nelson Price
Wayne Count...
⁄ Position the mouse over the area to the left of the record you want to delete ( changes to ) and then click to select the record.
1/1/2005
Membership : ...
¤ Click record.
Simon Paul Linda Frank David Nancy Stacy Ann Amy Sara Diane Josh Daniel
8
12:00 PM
to delete the
Evans Fraser Harris Hill Jones King Lee Lewis Martin Miller Morris Nelson Price
Wayne Count...
Membership : ...
The record disappears. A warning dialog box appears.
12:00 PM
‹ Click Yes to permanently delete the record.
65
CHANGE THE FONT OF DATA Book ID You can change the font, style, size and color of data in a table to customize the appearance of the table.
T
For example, you may want to use a smaller font size for your data to display more information on the screen at once. When you change the font of data, all the data in the table will display the change.
S ihsecap E s c rf epa H H s’hgu tS i l etaW l ehT siruoT ehT o b wo C yM sednalC T h e acigaM
Title
Year Published Pages
1 Spaceships in Orbit
1988
360
2 Escape from Reality
1990
400
3 Hugh’s Haunted Castle
1984
315
4 Still Waters Run Deep
1996
375
5 The Tourist
1999
545
6 The Cowboy Invasion
1993
250
7 My Clandestine Ways
2001
325
8 The Magical Lilac Tree
1997
425
CHANGE THE FONT OF DATA
Times New Roman
Tribute Electronics : ...
⁄ Click Format.
Products : Table
12:00 PM
Tribute Electronics : ...
¤ Click Font.
‹ To select a new font
The Font dialog box appears.
for the data, click the font you want to use.
› To select a new style for the data, click the style you want to use.
66
Bold
12
Products : Table
12:00 PM
ˇ To select a new size for the data, click the size you want to use. Á To underline the data, click Underline ( changes to ).
Edit Tables
What determines which fonts are available on my computer?
Tip
The fonts available on your computer depend on the programs installed on your computer, the setup of your computer and the printer you are using. You can obtain additional fonts at stores that sell computer software and on the Internet.
Tip
3
Why do some fonts display the symbol in the Font dialog box?
In the Font dialog box, the symbol beside a font indicates an OpenType font. An OpenType font will print exactly as it appears on your screen. A font that does not display the symbol in the Font dialog box may not print exactly as it appears on your screen.
AD3 PUSH
Arial COMPACT COMPACT
POWER
Re
RESET
AD3
Bold
Time
12
Blue
Tribute Electronics : ...
‡ To select a new color for the data, click this area to display a list of the available colors. ° Click the color you
Products : Table
12:00 PM
This area displays a preview of how the data will appear in your table.
Tribute Electronics : ...
Products : Table
12:00 PM
The data in your table displays the changes.
· Click OK to confirm your changes.
want to use.
67
HIDE A FIELD
You can temporarily hide a field in a table to reduce the amount of information displayed on your screen.
City
e Phone State Zip Cod 710 512-555-8973
TX 78 5-9822 101 305-55 -0231 ne Austin 33 La ee Tr e pl FL Ap 65 55 Miami 90011 213-5 55-4520 Jones CA Steven Drive 4 es el ng A 1 2 s Lo s 4 w 1910 5-5 5-8203 Andre 8910 Colt Rd. hia PA lp de la hi P ith 72231 501-55 5-6090 Sm R A Kirk Drive 21 5 ck o R le Litt 10199 212-5 5-4982 Taylor NY Sunset St. 44 rk Yo 0 5 ew N 97208 3-55 Roberts OR Walker Ave. 9 68 d n la rt o P Hunter 779 Pine St. Morgan
Last Name
Address
When you hide a field, Access does not delete the field. You can redisplay the field at any time. HIDE A FIELD
Order ID Emerald Creek Electronics
1 2 3 4 5 6 7 8 9 10 11 12 13 14
Tribute Electronics : ...
⁄ Click the name of the field you want to hide. The field is highlighted.
68
Order Details : Table
12:00 PM
¤ Click Format. ‹ Click Hide Columns.
Tribute Electronics : ...
The field disappears from your table.
Order Details : Table
12:00 PM
Edit Tables
Tip
When would I hide a field?
Tip
Hiding a field can help you review information of interest in a table by removing unnecessary data from your screen. For example, if you want to browse through only the names and telephone numbers of your customers, you can hide the fields that display other information in your table.
First Name Last Name
Phone No.
How can I hide multiple fields in my table?
To hide more than one field at the same time, you must first select all the fields you want to hide. Position the mouse over the name of the first field you want to hide ( changes to ). Then drag the mouse until you highlight all the fields you want to hide. To hide the selected fields, perform steps 2 and 3 on page 68.
1/12/2002 2/3/2002 12/3/2001 12/8/2001 1/25/2002 2/18/2002 2/23/2002 12/10/2001 2/28/2002 1/4/2002 12/13/2001 1/8/2002 12/8/2001 12/15/2001
Address
Daniel Helen
Price Reed
(512) 555-8973 (305) 555-9822
Kevin Jack Julie
Turner Adams Brown
(213) 555-0231
8910 Colt Rd.
(215) 555-4520 (501) 555-8203
21 Kirk Dr. 44 Sunset St.
3
65 Apple Tree Ln. 4 Steven Dr.
512 518 524 535 511 538 512 511 524 511 512 511 535 512
Order ID
Emerald Creek Electro
Tribute Electronics : ...
Order Details : Table
12:00 PM
REDISPLAY A FIELD
¤ Click Unhide Columns.
⁄ Click Format.
The Unhide Columns dialog box appears.
Tribute Electronics : ...
Order Details : Table
This area displays a list of all the fields in the table. A check mark ( ) appears beside each field that is currently displayed.
12:00 PM
› Click Close to close the Unhide Columns dialog box. The field reappears in your table.
‹ Click the box (
) beside the hidden field you want to redisplay ( changes to ).
69
FREEZE A FIELD
You can freeze a field in a table so the field will remain on your screen at all times.
ORDERS Table Company Name
Order ID
Product
Quantity
Unit Price
1
Pet Superstore
Vitamins
12
$20.00
2
Petterson Inc.
Bulk Dry Food
15
$18.00
3
Martin Vet Supplies
Diet Dog Food
30
$10.00
4
Greg’s Pet Store
5-Variety Biscuits
50
$3.50
5
Pet Superstore
Canned Dog Food
24
$3.00
6
Feline Foods Inc.
Dry Cat Food
40
$4.00
7
Weasels R Us
Ferret Pellets
30
$6.50
8
Purrrfect Portions
Dry Cat Food
24
$4.00
9
Doggone Yummy Inc.
Steak-flavored Bones
40
$1.25
10 11
Jim’s Pets Allen’s Dog Kennel
Hamster Treats Puppy Kibble
30 20
$5.00 $8.50
12
B&T Food Suppliers
Gerbil Mix
35
$4.50
13
Pet Superstore
Parrot Food
25
$17.00
14
Kitty-Mart
Dry Cat Food
35
$4.00
15
Canine Nutrition Inc.
Rawhide Chew Sticks
15
$2.00
FREEZE A FIELD
Company Name American Outdoors Camping Depot Camping USA Hiker's Heaven Outer World Portage Point Reel Fishing Rod 'n' Reel Sports Superstore Total Sports Ultimate Outdoors
Outdoor Sporting ...
⁄ Click the name of the field you want to freeze. The field is highlighted.
70
Sports Superstore Total Sports Ultimate Outdoors
Customers : Table
12:00 PM
Note: To freeze more than one field at the same time, select the fields you want to freeze. To select multiple fields, see page 54.
Outdoor Sporting ...
¤ Click Format. ‹ Click Freeze Columns.
Customers : Table
12:00 PM
Note: If Freeze Columns does not appear on the menu, position the mouse over the bottom of the menu to display the menu option.
Edit Tables
Tip
3
When would I freeze a field?
Freezing a field allows you to keep important data displayed on your screen as you move through data in a large table. For example, you can freeze a field that contains the product numbers in a table so the numbers will remain on your screen while you scroll through the product information.
Outdoor Sporting ...
› Click any cell in the table to deselect the field. Access moves the field to the left side of the table. The black vertical line to the right of the field indicates that the field is frozen.
Customers : Table
Product Number
The frozen field will remain on your screen as you move through the other fields in the table. To move through the other fields in the table, click or .
Vitamins
n 4864 Inc.
Bulk Dry Food
Vet4873 Supplies
12:00 PM
Product
4863 erstore
Diet Dog Food
et4902 Store
5-Variety Biscuits
4861 erstore
Canned Dog Food
4873 oods Inc.
Dry Cat Food
R4774 Us
Ferret Pellets
4621 t Portions
Dry Cat Food
4569 Inc. e Yummy
Steak-flavored Bones
ts4432
Hamster Treats
Outdoor Sporting ...
Customers : Table
UNFREEZE ALL FIELDS
⁄ Click Format. ¤ Click Unfreeze All Columns.
Note: If Unfreeze All Columns does not appear on the menu, position the mouse over the bottom of the menu to display the menu option.
12:00 PM
When you unfreeze a field, Access will not return the field to its original location in the table. To rearrange fields in a table, see page 45.
71
Text
DATA RED REQUI Text
Text
Text
CHAPTER 4
Design Tables Would you like to customize your tables to better suit your needs? In this chapter, you will learn how to add and delete fields, create a lookup column and much more.
Change the View of a Table ..............74 Add a Field ......................................76 Delete a Field ..................................78 Rearrange Fields ..............................79 Display Field Properties......................80 Add a Field Description ....................81 Change a Data Type ........................82 Select a Format ................................84 Change the Field Size........................86 Change the Number of Decimal Places ............................................88 Add a Caption..................................90 Set a Default Value ............................91 Data Entry Required ..........................92 Add a Validation Rule........................94 Create an Input Mask ........................96 Create a Field to Store Pictures ........102 Create a Lookup Column..................106 Create a Yes/No Field ....................110 Create a Hyperlink Field ..................114 Using Smart Tags ............................120
CHANGE THE VIEW OF A TABLE
You can view a table in four different ways. Each view allows you to perform different tasks.
Invoice Number
23452 Grant Lewis Smith Grant Lewis Smith Grant Lewis Smith Fraser Turner Fraser Turner Morris Fraser
CHANGE THE VIEW OF A TABLE
Order ID
Outdoor Sporting Go...
In this example, the table appears in the Datasheet view.
⁄ Click
in this area to display the table in a different view.
74
Order Details : Table
12:00 PM
¤ Click the view you want to use.
Outdoor Sporting Go...
The table appears in the view you selected. In this example, the View button changed from to .
Order Details : Table
12:00 PM
To quickly switch between the Datasheet ( ) and Design ( ) views, click the View button.
Design Tables
4
THE TABLE VIEWS
Design View
Datasheet View
The Design view displays the structure of a table. You can change the settings in this view to specify the kind of information you can enter into a table.
The Datasheet view displays all the records in a table. The field names appear across the top of the window and the information for one record appears in each row. You can review, enter and edit records in this view.
Invoice Number
23452 Grant
The Field Name area displays the name of each field in a table.
The Data Type area displays the type of data you can enter into each field, such as text or numbers.
The Field Properties
Lewis Smith Grant Lewis Smith Grant Lewis Smith Fraser Turner Fraser Turner Morris Fraser
area shows the properties for the current field.
PivotTable View
PivotChart View
The PivotTable view allows you to summarize and analyze the data in a table. When you first display a table in this view, the PivotTable is empty and you must add the fields you want the PivotTable to display. For information on using the PivotTable view, see page 232.
The PivotChart view allows you to display a graphical summary of the data in a table. When you first display a table in this view, the PivotChart is empty and you must add the fields you want the PivotChart to display. For information on using the PivotChart view, see page 238.
75
ADD A FIELD
You can add a field to a table when you want the table to include an additional category of information.
#
A field is a specific category of information in a table, such as the phone numbers of all your clients. ADD A FIELD
Outdoor Spor ...
⁄ Click the name of the field you want to appear after the new field. A triangle ( ) appears beside the field name.
76
Order Details ...
12:00 PM
To add a field to the end of your table, click the area directly below the last field name. Then skip to step 3.
Outdoor Spor ...
¤ Click to add a field to your table. A new row appears where you can enter information for the new field.
Order Details ...
12:00 PM
‹ Type a unique name for the field and then press the Enter key.
Design Tables
Tip
What should I consider when adding fields to a table?
What data type should I select for my new field?
Tip
The data type you should select depends on the type of information you want to enter in the field. For example, you can choose the Currency data type for a field you want to contain monetary values, such as the prices of products. For more information on data types, see page 82.
order #
Province quantity Postal code
Make sure each field you add to a table relates directly to the subject of the table. You should also make sure you separate the information you want to include in a table into its smallest parts, such as First Name and Last Name.
S
FIELD
ers Custom er ID Custom
4
Unit Price
Product
Text
mbo
Rod/Reel Co
Tent
Last Name
Currency
ts Hiking Boo Kit g n yi T Fly g Bag Sleepin addle P e o Can
me t Na Firs
s res Add
Number
Memo
Date/Time
1
Text
Date/Time
Outdoor Spo...
12:00 PM
Order Detail...
Access automatically sets the data type for the new field to Text.
› To specify a different data type for the new field, click the arrow ( ) to display a list of data types.
ˇ Click the appropriate data type for the field.
Outdoor Spor ...
The new field appears in your table.
Order Details ...
12:00 PM
To return to the Design view, click .
Á Click
to save your change.
‡ Click
to display your table in the Datasheet view.
77
DELETE A FIELD
If you no longer need a field, you can permanently delete the field from a table.
Gard
Recipe ID 1
e in g s S e rv Pizza 4 Veggie utes in m 1 45 Dinner inuetes mim srtatio1n0T fa k ute6s a a in p re B Pre 30 m 4s inutes minute Lun2c5hm s 10 te u in m 2 5 r 1 e n Din utes 45 smtin 4 Breakfa 2 Dinner 2 Lunch st 7 Breakfa 8 Dinner Dinner
Meal
le
Tab RECIPES ame
N R e c ip e a Lasagn ncakes a P 2 ps ork Cho 3 P alad arden S G 4 t le e Om 5 Kiev Chicken 6 dwich lub San C 7 l a e Oatm 8 teak epper S P 9 ork P st a Ro 10
en S alad 10 m inute s 30 m inute s 15 m inute s
Before you delete a field, make sure the field is not used in any other objects in your database, such as a form, query or report. You cannot delete a field used to create a relationship with another table in your database. For information on relationships, see page 128.
DELETE A FIELD
Outd...
⁄ Click the name of the field you want to delete.
78
12:00 PM
Prod...
¤ Click the field.
to delete
Outd...
12:00 PM
Prod...
A confirmation dialog box may appear.
The field disappears from your table.
‹ Click Yes to permanently delete the field.
› Click
to save your change.
REARRANGE FIELDS
You can change the order of fields to better organize the information in a table.
Design Tables
4
Meal
Dinner st Breakfa Lunch Dinner
st BreakSfa ervings Dinner ame 4 Nle eb e ip nch c im Lu a e T y T n fr R st n Stir- Preparatio Breakfa 1 Chicke s te t Dinner 6 2a 5 minu # Omele ner z in Recipe ID iz D s P te 4 15 minu Veggie 1 na inutes m Lasag 5 2 4 es 2 k a c s n te Pa 4 psinu 45hom 3 Pork C udtes ala 2 nmSin 4 Ga1rd0e Sainlaudtes 2 F3ru0itm 5 s irloininute 7 10Sm 6 rk o P s t Roinasute 8 10 m 7 s te 30 minu 8 tes 45 minu 9
RECIPES
When you rearrange fields in the Design view, Access also displays the changes in the Datasheet view of a table. For information on the views of a table, see page 74.
10
REARRANGE FIELDS
Units In Stock Units In Stock
Number
Number
Outdoor Spo...
⁄ Click the area to the left of the field you want to move. The field is highlighted.
Products : T...
12:00 PM
¤ Position the mouse over the area to the left of the field ( changes to ) and then drag the field to a new location.
Outdoor Spo...
The field appears in the new location.
Products : T...
12:00 PM
‹ Click
to save your change.
A thick line shows where the field will appear.
79
DISPLAY FIELD PROPERTIES
You can display the properties for each field in a table. The field properties are a set of characteristics that control how data is entered, displayed and stored in a field.
Maxim numb um chara er of cters this fie for ld
6
For example, a field property can specify the maximum number of characters a field can accept. DISPLAY FIELD PROPERTIES
Outdoor Sporting Go...
This area displays the field name and data type for each field in your table.
80
Order Details : Table
You can click or to browse through the fields.
12:00 PM
Outdoor Sporting Go...
⁄ Click the name of a field to display the properties for the field. A triangle ( ) appears beside the field name.
Order Details : Table
12:00 PM
This area displays the properties for the field you selected. Note: The available properties depend on the data type of the field. For information on data types, see page 83.
ADD A FIELD DESCRIPTION
You can add a description to a field to help you determine the kind of information you should enter in the field.
Design Tables
4
REMINDER
Enter final grade in percentage only ER DED R R INDM N IN E EIM REM RER
You can use up to 255 characters to describe a field. ADD A FIELD DESCRIPTION
Outdoor Sporting Go...
⁄ Click the Description area for the field you want to add a description to.
Order Details : Table
12:00 PM
¤ Type the description.
Note: The Property Update Options button ( ) may appear, allowing you to automatically add the field description to all your forms or reports that display the field. For more information, see the top of page 85.
‹ Click
› Click
to save your change.
Outdoor Sporting Go...
ˇ Click anywhere in the field you added the description to.
Order Details : Table
12:00 PM
The description for the field appears in this area. To return to the Design view, click .
to display your table in the Datasheet view.
81
CHANGE A DATA TYPE Order ID
Company Name
Product
Quantity
Unit Price
You can change the type of data you can enter into a field.
4
$3.50
Feline Foods Inc.
$3.00
5 Changing the data type for a field helps prevent errors when entering data in the field. Access will not accept data that does not match the data type you specify. For example, you cannot enter text into a field with the Number data type.
Weasels R Us
$4.00
6
7
10
9
$6.50
Purrrfect Portions
8
$1.25 $4.00
Doggone Yummy Inc.
$5.00
CHANGE A DATA TYPE
Memo Memo
Outdoor Sportin...
⁄ Click the Data Type area for the field you want to change to a new data type. An arrow ( ) appears.
82
Products : Table
12:00 PM
¤ Click the arrow (
)
to display a list of data types.
‹ Click the data type you want the field to use.
Outdoor Sportin...
The field changes to the new data type.
› Click to save your change.
Products : Table
12:00 PM
If you change the data type for a field that contains data, Access will display an error message if it encounters errors while converting the data. To delete the data that is causing the errors, click Yes. To cancel the change, click No.
Design Tables
4
DATA TYPES Text
Accepts entries up to 255 characters long that include any combination of text and numbers, such as names or addresses. Make sure you use this data type for numbers you will not use in calculations, such as phone numbers, product numbers or zip codes. Memo
Number
Accepts entries up to 65,535 characters long that include any combination of text and numbers, such as notes, comments or descriptions.
M
emo
Accepts numbers you want to use in calculations. For calculations that involve monetary values, use the Currency data type.
Date/Time
Currency
Accepts only dates and times.
Accepts monetary values.
FEDERAL RESERVE NOTE 1111111000
1111111000
ONE
A 1
AutoNumber
Yes/No
Automatically numbers each record for you. The numbers may not begin at 1.
Accepts only one of two values––Yes/No, True/False or On/Off.
7777777
7777777
GEORGE WASHINGTON
THE UNITED STATES OF AMERICA
Yes
1
No
3 2
1 OLE Object
Hyperlink
Accepts OLE objects. An OLE object is an item created in another program, such as a document, spreadsheet, picture or sound.
Accepts hyperlinks you can select to jump to a document or Web page.
83
SELECT A FORMAT
You can select a format to customize the way information appears in a field. For example, you can select the way you want numbers or dates to appear.
22-Jan-04
1/22/2004
15-Feb-04
2/15/2004 2-Apr-04
4/2/2004
20-Mar-04
3/20/2004
31-Jan-04
1/31/2004
1-Mar-04
Long Date
3/1/2004 20-Feb-04
2/20/2004
Medium Date
5-Jan-04
1/5/2004 17-Feb-04
2/17/2004 14-Apr-04
4/14/2004
Short Date
Selecting a format will not change how information is stored in a table. SELECT A FORMAT
Currency
Outdoor Sporting Go...
⁄ Click the field that contains the data you want to display in a new format.
84
12:00 PM
Products: Table
¤ Click the area beside Format. An arrow (
appears.
)
$3,456.79
Outdoor Sporting Go...
‹ Click the arrow (
) to display a list of formats. Note: A list of formats only appears for fields with the Number, Date/Time, Currency, AutoNumber or Yes/No data type. For information on data types, see page 82.
Products: Table
12:00 PM
› Click the format you want to use.
Design Tables
Tip
What formats are available?
Why does the Property Update Options button ( ) appear when I change the format of a field?
Tip
There are several different formats that you can choose from. For example, you can format numbers as currency using the dollar ($) or Euro ( ) symbol, as a percentage, or as scientific notation. You can also format dates and times using many different styles, such as "Saturday, June 19, 2004" or "5:34:23 PM." 456789 April
You can use the Property Update Options button ( ) to automatically change the format of the current field in all your forms or reports that display the field. Click the Property Update Options button to display a list of options and then select the option you want to use. The Property Update Options button is available only until you perform another task.
12 A
0
18 38 1 ril
Ap
9
1 23
C C E S
S
y Ma
Currency
Aut oma
4
tic
6
$3,456.79
Euro
3,456.79
Percent
123.00%
Scientific
3.46E+03 Long Date Saturday, June 19, 2004 Short Date
6/19/2004
Long Time
5:34:23 PM
22
Currency
Outdoor Sporting Go...
The format you selected appears in this area.
Products: Table
ˇ Click
12:00 PM
to save your
change.
Á Click
to display your table in the Datasheet view.
Outdoor Sporting Go...
Products: Table
The data displays the format you selected.
12:00 PM
To return to the Design view, click .
Access will automatically change any data you enter in the field to the new format. For example, Access will automatically change 1234 to $1,234.00.
85
CHANGE THE FIELD SIZE
You can change the size of a text or number field to specify the maximum size of data that you can enter in the field.
State
First Name
Last Name
City
Jack
Adams
New York
N
Y
Ryan
Smith
Boston
M
A
Jason
Cook
San Diego
C
A
Ann
Lewis
Jacksonville
F
L
Paul
Fraser
Nashville
T
N
Janet
Young
Atlanta
G
A
You should select the smallest possible field size for data. Smaller field sizes can be processed faster, require less memory and use less storage space. Changing the field size also helps you reduce errors when entering data. For example, if you set the size of a text field to 2, you can enter CA but not California.
TEXT FIELDS
50
Outdoor Spo...
⁄ Click the field you want to accept a maximum number of characters.
Order Detail...
12:00 PM
The area beside Field Size displays the maximum number of characters you can currently type in the field. The default setting is 50.
¤ Double-click the number to highlight the number.
86
Outdoor Spo...
‹ Type the maximum number of characters you want the field to accept. Note: You can enter a number from 0 to 255.
› Click
to save your change.
Order Detail...
12:00 PM
A warning dialog box appears if you are reducing the size of a text field that contains data. Access will shorten any data that is longer than the new field size. To continue, click Yes.
Design Tables
Tip
What field sizes are available for number fields?
Decimal Places
Range
Field Size
Access offers several field sizes for number fields. Some field sizes allow you to only enter whole numbers. If you want to be able to enter numbers with decimal places, such as 1.23, you must select the Single, Double or Decimal field size.
Byte
0 to 255
none
Integer
-32,768 to 32,767
none
Long Integer
-2.1x109 to 2.1x109
none
Single
-3.4x1038 to 3.4x1038 308
Double
-1.8x10
Decimal
-1028 to 1028
4
308
to 1.8x10
7 15 28
NUMBER FIELDS
Byte
Outdoor Spor...
Order Details...
⁄ Click the field you want to only accept a certain type of number.
¤ Click the area beside Field Size. An arrow (
appears.
)
‹ Click the arrow (
12:00 PM
) to display a list of options.
Outdoor Spo...
Order Detail...
› Click the type of number you want the field to accept. Note: For information on the types of numbers available, see the top of this page.
ˇ Click change.
to save your
12:00 PM
A warning dialog box appears if you are reducing the size of a number field that contains data. Access will change or delete data that is larger than the new field size. To continue, click Yes.
87
CHANGE THE NUMBER OF DECIMAL PLACES
You can specify how many decimal places you want numbers to display in a field.
00 0 1 . 0 0 0
0
0 Changing the number of decimal places will not affect the way numbers are stored or used in calculations.
You can display up to 15 decimal places after the decimal point. CHANGE THE NUMBER OF DECIMAL PLACES
1
Outdoor Sporting Go...
⁄ Click the field that contains the data you want to display a specific number of decimal places.
12:00 PM
Order Details : Table
¤ Click the area beside Decimal Places. An
arrow (
) appears.
Outdoor Sporting Go...
‹ Click the arrow (
) to display a list of decimal place options.
Order Details : Table
› Click the number of decimal places you want the data in the field to display. Note: The Auto option will usually display numbers with two decimal places.
88
12:00 PM
Design Tables
Tip
Why does the Property Update Options button ( ) appear when I change the number of decimal places for a field?
4
Why doesn't my data display the number of decimal places I specified?
Tip
Changing the number of decimal places will not change the appearance of numbers if the Format property of the field is blank or set to General Number. To change the Format property of a field, see page 84.
You can use the Property Update Options button ( ) to automatically update the number of decimal places for the field in all your forms or reports that display the field. Click the Property Update Options button to display a list of options and then select the option you want to use. The Property Update Options button is available only until you perform another task.
1
1
Outdoor Sporting Go...
The number of decimal places you selected appears in this area.
Order Details : Table
12:00 PM
ˇ Click
to save your change.
Á Click
to display your table in the Datasheet view.
Outdoor Sporting Go...
The data displays the number of decimal places you specified. When you enter data in the field, Access will automatically display the data with the correct number of decimal places.
Order Details : Table
12:00 PM
Note: If Access changes decimal places you type to zeros (example: 12.34 changes to 12.00), you need to change the field size. To change the field size, see page 86. To return to the Design view, click .
89
ADD A CAPTION Preparation Time Recipe
You can add a caption to a field. The caption will appear as the heading for the field instead of the field name.
Time
Servings Calories
A caption can be longer and more descriptive than a field name. After you add a caption to a field, any forms, reports or queries you create that include the field will display the caption instead of the field name. ADD A CAPTION
1
Outd...
12:00 PM
Orde...
⁄ Click the field you want to add a caption to.
‹ Type the text for
¤ Click the area beside
› Click
Caption.
Note: If a caption already exists, drag the mouse over the caption to highlight the text.
90
the caption. to save your change.
ˇ Click
to display your table in the Datasheet view.
Outd...
12:00 PM
Orde...
The caption you entered replaces the field name in your table.
To return to the Design view, click
.
SET A DEFAULT VALUE
Design Tables
You can specify a value that you want to appear automatically in a field each time you add a new record. Setting a default value saves you from having to repeatedly type the same data.
4
For example, if most of your customers live in California, you can set "California" as the default value for the State field. In a field that contains dates, such as an Order Date field, you can set the current date as the default value for the field.
SET A DEFAULT VALUE
Outdoor Sporting ...
⁄ Click the field you want
Customers : Table
12:00 PM
to have a default value.
Note: To set the current date as the default value, type =Date().
¤ Click the area beside
› Click
Default Value.
change.
‹ Type the text or
ˇ Click
number you want to set as the default value.
to save your
to display your table in the Datasheet view.
Outdoor Sporting ...
The default value automatically appears in the field each time you add a new record. You can accept the default value or type another value.
Customers : Table
12:00 PM
Note: Setting a default value will not affect existing data in the field. To return to the Design view, click
.
91
DATA ENTRY REQUIRED
You can specify that a field must contain data for each record. This prevents you from leaving out important information when entering data.
Item
Qty
Amount
Invoice # 16437 16438 16439 16440
For example, a table containing invoice information can require data in the Invoice Number field.
16441
DATA ENTRY REQUIRED
Yes Yes
Outdoor Sporting G...
Mailing List : Table
12:00 PM
⁄ Click the field you want to always contain data.
‹ Click the arrow ( ). › Click Yes to specify
¤ Click the area beside
that the field must contain data.
Required. An arrow (
appears.
)
Outdoor Sporting G...
12:00 PM
ˇ To specify if you want the
‡ Click Yes or No
field to accept a zero-length string (""), click the area beside Allow Zero Length. An arrow ( ) appears.
to specify if you want the field to accept a zero-length string.
Á Click the arrow ( 92
Mailing List : Table
).
° Click
to save your changes.
Design Tables
Tip
4
What is a zero-length string?
A zero-length string ("") indicates that no data exists for the field. A zero-length string is useful when a field is set to require data, but no data exists. For example, if the Fax Number field must contain data, but a customer does not have a fax number, you can enter a zero-length string in the field. You can allow zero-length strings only in fields with the Text, Memo or Hyperlink data type. For information on data types, see page 82.
ID
First Name
Last Name
Phone
Fax
1
Linda
Harris
555-4433
2
Frank
Hill
555-1234
3
David
Jones
555-6677
555-6678
4
Nancy
King
555-1215
555-1216
5
Stacy
Lee
555-2200
6
Ann
Lewis
555-1543
555-1550 555-6236
7
Amy
Martin
555-6235
8
Sara
Miller
555-8976
555-4434
CAN CONTAIN ZERO-LENGTH STRINGS
To enter a zero-length string, type "" in a cell. When you enter a zero-length string, the cell will appear empty.
Outdoor Sporting G...
If your table contains data, a dialog box appears, asking if you want to check if the field contains data for all existing records.
Mailing List : Table
12:00 PM
Note: If you want to check the field, click Yes.
‚ Click
to display your table in the Datasheet view.
Amy Sue Helen Paul
Martin Grant Reed Fraser
[email protected] [email protected] [email protected] [email protected]
David Sara Linda
Jones Miller Harris
[email protected] [email protected]
Outdoor Sporting ...
When you enter a new record, an error message will appear if you do not enter data in the field.
Mailing List : Table
12:00 PM
To close the dialog box so you can enter data in the field, click OK. To return to the Design view, click .
· If you do not want to check the field, click No. 93
ADD A VALIDATION RULE
You can add a validation rule to help reduce errors when entering data in a field. A field that uses a validation rule can only accept data that meets the requirements you specify.
Country Canada USA Mexico USA Canada
Tex t USA = must or C ana da
USA ADD A VALIDATION RULE
Outdoor Sporting ...
⁄ Click the field you want to use a validation rule. ¤ Click the area beside Validation Rule.
Products : Table
12:00 PM
‹ Type the validation rule you want to use to limit the data you can enter into the field. Note: For examples of validation rules, see the top of page 95.
Outdoor Sporting ...
› To create the error message you want to appear when incorrect data is entered, click the area beside Validation Text. ˇ Type the error message you want to appear.
94
Products : Table
12:00 PM
Note: If you do not specify an error message, Access will display a standard message.
Á Click
to save your changes.
Design Tables
Tip
What validation rules can I use?
Tip
Here are some examples of validation rules that you can use. For more examples, see page 214.
RULE
DESCRIPTION
<1000
Must be less than 1000
<>0
Cannot be zero
4
What should my error message contain?
When you enter incorrect data, the error message that appears should clearly explain why the data you entered is incorrect. For example, the error message "You must enter a number between 1 and 100" is more informative than the message "Data Rejected."
Between 100 and 200 Must be between 100 and 200 USA or Canada
Must be USA or Canada
Like “????”
Must have 4 characters
Like “##”
Must have 2 numbers
VALIDATION
RULES
Outdoor Sporting ...
A dialog box appears, asking if you want to check if the existing data in the field meets the requirements you specified.
‡ If you do not want to check the existing data, click No.
Products : Table
12:00 PM
Note: If you want to check the existing data, click Yes.
° Click
to display your table in the Datasheet view.
Outdoor Sporting G...
When you enter data that does not meet the requirements specified for the field, the error message you typed in step 5 will appear.
Products : Table
12:00 PM
To close the dialog box so you can enter different data, click OK. To return to the Design view, click
.
95
CREATE AN INPUT MASK Data Appearance
Input Mask You can create an input mask to control the type of information you can enter in a field. Input masks reduce errors and ensure data has a consistent appearance.
( 2 0 6 ) 5 5 5 – 1 2 1 2 8 3 1 – 8 6 – 7 1 8 0 9 8 0 5 2 – 6 3 9 9 6 3 2 1 5 1 : 1 2 : 0 0
AM
The Input Mask Wizard provides commonly used input masks that you can choose from.
9 / 2 7 / 1 9 6 9
You can use the Input Mask Wizard only in fields with the Text or Date/Time data type. For information on data types, see page 82.
2 7 – S e p – 6 9
1 3 : 1 2 0 1 : 1 2
A M
CREATE AN INPUT MASK USING THE WIZARD
Phone Number
Tribute Electronics : ...
⁄ Before starting the Input Mask Wizard, you must save your table. To save your table, click . ¤ Click the name of the field you want to use an input mask. 96
Customers : Table
12:00 PM
Tribute Electronics : ...
‹ Click the area beside Input Mask. A button (
)
appears.
› Click the button ( to start the Input Mask Wizard.
)
The Input Mask Wizard appears. This area displays the available input masks and how the data will appear in the field.
ˇ Click the input mask you want to use.
(206) 555-1212
Customers : Table
12:00 PM
Á To try the input mask you selected, press the Tab key and then type the appropriate data.
‡ Click Next to continue.
Design Tables
Tip
Why does a dialog box appear when I try to start the Input Mask Wizard?
When you try to start the Input Mask Wizard for the first time, a dialog box appears, stating that the wizard is not installed on your computer. To install the wizard, click Yes.
Tip
4
How can an input mask save me time when I enter data in a field?
Input masks can save you time by automatically entering characters for you, such as brackets ( ), hyphens (-) and slashes (/). For example, when you type 2015551234 in a field that uses the Phone Number input mask, Access will change the data to (201) 555-1234.
2015551234 (201) 555-1234
Tribute Electronics : ...
Customers : Table
12:00 PM
This area displays the input mask you selected.
· Click the placeholder
° To select a placeholder
Note: When you enter data in the field, the data you type will replace the placeholder characters. For example, (___) ___-____ will change to (555 ) 555-3874.
character for the input mask, click in this area.
character you want to use.
Tribute Electronics : ...
‚ To try the input mask with the placeholder character you selected, press the Tab key and then type the appropriate data.
Customers : Table
12:00 PM
— Click Next to continue. You can click Back at any time to return to a previous step and change your selections.
97
CREATE AN INPUT MASK 92799
When you create an input mask, the wizard may ask how you want to store the data you enter in the field.
WITHOUT SYMBOLS
9/27/99 WITH SYMBOLS
You can store data with or without symbols. Storing data without symbols saves storage space on your computer. CREATE AN INPUT MASK USING THE WIZARD (CONTINUED)
Tribute Electronics : ...
± Click an option to specify how you want to store the data in the field ( changes to ).
Customers : Table
Note: This screen does not appear for some input masks. If the screen does not appear, skip to step 14.
¡ Click Next to continue.
98
12:00 PM
Tribute Electronics : ...
This message appears when you have provided all the information the wizard needs to create the input mask.
Customers : Table
12:00 PM
™ Click Finish to close the wizard.
Design Tables
Tip
After creating an input mask, why doesn't the data I enter appear the way I expect?
After you use an input mask to enter data in a field, Access will display the data using the format set for the field. For example, if you enter the date 01/25/2004 in a field that uses the Short Date input mask and the Long Date format, the date will automatically change to Sunday, January 25, 2004 after you press the Enter key. To select a format for a field, see page 84.
Tribute Electronics : ...
This area displays the input mask.
£ Click
to save the input mask.
4
Customers : Table
¢ Click
to display your table in the Datasheet view.
12:00 PM
Short
Date In
01/25
put Ma
/2004
sk:
Form Long at: Date
Sund
ay, J
anua
r y 25
, 200
4
Tribute Electronics : ...
Customers : Table
USE AN INPUT MASK
⁄ Click an empty cell in the field that uses the input mask.
¤ To move to the beginning of the cell, press the key.
12:00 PM
Note: Access will only accept characters specified by the input mask. For example, you can only enter numbers in a field that uses the Phone Number input mask.
Home
‹ Type the appropriate data and then press the
Enter
key.
99
CREATE AN INPUT MASK
ISBN You can create your own input mask to establish a pattern for data you can enter in a field.
Book Title
Price
Expert Snowboarding The Boston Incident Cream of the Crop The Enchanted Pond A Tree for Marie A Rainy Winter's Day Mysteries of the Pacific Second Star on the Right
$23.95 $29.95 $27.99 $19.95 $9.99 $17.95 $34.95 $14.99 $0.00
You may want to create your own input mask if the Input Mask Wizard does not offer an input mask that suits the data you want to enter in a field. To create an input mask using the wizard, see page 96.
CREATE YOUR OWN INPUT MASK
Tribute Electronics : ...
⁄ Click the name of the field you want to use an input mask.
100
Employees : Table
¤ Click the area beside Input Mask.
‹ Type the input mask you want to use.
12:00 PM
Tribute Electronics : ...
› Click
to save your change.
Employees : Table
ˇ Click
12:00 PM
to display your table in the Datasheet view.
Design Tables
Tip
How do I remove an input mask?
Tip
If you no longer want a field to use an input mask, you can delete the input mask. In the Input Mask area for the field, position the mouse to the left of the input mask and then drag the mouse until you highlight the entire input mask. Then press the Delete key to delete the input mask. Format
!\(999") "000\-0000;;_
4
Why does the Property Update Options button ( ) appear when I create an input mask?
You can use the Property Update Options button ( ) to automatically update the format of the field in all your forms or reports that display the field. Click the Property Update Options button to display a list of options and then select the option you want to use. The Property Update Options button is available only until you perform another task.
Delete
INPUT MASK CHARACTERS You can use these characters to create an input mask.
Linda Frank David Nancy Stacy Ann Amy Sara Diane Josh Daniel Helen Emily Ryan Mark
0 Numbers 0 to 9, required. Plus (+) and minus (-) signs not allowed.
Harris Hill Jones King Lee Lewis Martin Miller Morris Nelson Price Reed Ross Smith Taylor
Tribute Electronics : ...
9 Number or space, optional. Plus (+) and minus (-) signs not allowed. # Number or space, optional. Plus (+) and minus (-) signs allowed. L Letters A to Z, required. Employees : Table
12:00 PM
USE AN INPUT MASK
‹ Type the appropriate
⁄ Click an empty cell
data.
in the field that uses the input mask.
Note: Access will only accept characters specified by the input mask. In this example, you can enter only 7 digits in the field.
¤ To move to the beginning of the cell, press the Home key.
? Letters A to Z, optional. A Letter or number, required. a Letter or number, optional. & Character or space, required.
C Character or space, optional. .,:;-/ Decimal point and thousands, date and time separators. < Convert the following characters to lowercase. > Convert the following characters to uppercase. ! Display characters from right to left, rather than from left to right. \ Display the following input mask character. For example, \& will display &. Password Display an asterisk (*) for each character you type.
101
CREATE A FIELD TO STORE PICTURES
You can create a field that allows you to add a picture to each record in a table.
For example, you can create a field to store pictures of employees, houses for sale, artwork, recipes or products.
1
e Recipe Nam r-fry Chicken Sti
2
Omelet
3
a Deluxe Pizz
4
Lasagna
5
Pancakes
Recipe ID
re Recipe Pictu e Picture ip c e R
Access allows you to include pictures stored in several popular file formats, such as Bitmap (.bmp) and Windows Metafile (.wmf).
CREATE A FIELD TO STORE PICTURES
Tribute Electronics : ...
⁄ To create a field that will store pictures, click the name of the field you want to appear after the new field. A triangle ( ) appears beside the field name. 102
Products : Table
12:00 PM
To add a field that will store pictures to the end of your table, click the area directly below the last field name. Then skip to step 3.
Tribute Electronics : ...
¤ Click
to add a field to your table. A new row appears where you can enter information for the new field.
Products : Table
12:00 PM
‹ Type a unique name for the field and then press the Enter key.
Design Tables
Tip
Will the pictures I add to my table appear on a form?
When you create a form using a table that includes pictures, the form will display the pictures.
Contact ID
1
First Name
John
Last Name
Adams
Address
12 Willow Dr.
City
Jacksonville
State/Province
FL
Postal Code
32256
Country
USA
Home Phone
(904) 555-7816
Work Phone
(904) 555-1081
Tip
4
Can I add other types of files to a table?
You can add files such as documents, spreadsheets, sounds and videos to a table as you would add pictures to a table. When you double-click the cell containing a file in a table, the appropriate program will open and display or play the file.
Work Extension 232 Fax Number
(904) 555-1589
tions1
ifica Spec
A
B
C
2 3 4 5 6 7 8 9 10 11 12 13 14 15
Text
OLE Object
Tribute Electronics : ...
› To select the data type for the new field, click the arrow ( ) in the Data Type area. ˇ Click OLE Object.
Products : Table
Á Click changes.
12:00 PM
to save your
‡ Click to display your table in the Datasheet view.
Tribute Electronics : ...
ADD A PICTURE TO A RECORD
⁄ Click the cell for the
Products : Table
12:00 PM
¤ Click Insert. ‹ Click Object.
record you want to add a picture to.
The new field will appear in your table.
103
CREATE A FIELD TO STORE PICTURES
When adding a picture to a record in a table, you must specify where the picture is stored on your computer.
Postal Code House Pictures rk
10010
C: My Documents
02117
My Pictures House1
geles 90032 as 89116 CREATE A FIELD TO STORE PICTURES (CONTINUED)
Digital Camera
Tribute Electronics : ...
The Microsoft Office Access dialog box appears.
› Click Create from File to add a picture stored on your computer to the record ( changes to ).
104
Products : Table
12:00 PM
ˇ Click Browse to locate the picture on your computer.
Tribute Electronics : ...
This area shows the location of the displayed files. You can click this area to change the location.
Á Click the name of the picture you want to add to the record.
Products : Table
12:00 PM
‡ Click OK to confirm your selection.
Design Tables
Tip
Why would I add a link to a picture to my table?
How do I remove a picture I added to my table?
Tip
When you add a link to a picture, Access creates a connection to the original picture on your computer. Changes you make to the original picture will affect the picture in the table. If you choose not to add a link to a picture, Access stores a copy of the picture in your database. Changes you make to the original picture will not affect the picture in the table. Recipe ID Recipe Name Recipe Picture 1 Pepper Stir-fry Bitmap
Image Bitmap Image
2 Omelet
3 Deluxe Pizza Bitmap Image 4 Lasagna
Bitmap Image
5 Pancakes
Bitmap Image
4
To remove a picture from a table, click the cell containing the picture and then press the Delete key. Access will not delete the original picture stored on your computer.
Name
Recipe Picture
tir-fry
Bitmap Image
et zza
" lick "C
Bitmap Image Bitmap Image Delete
Tribute Electronics : ...
Products : Table
12:00 PM
This area displays the location and name of the picture you selected.
Note: For more information about adding a link to a picture, see the top of this page.
° To add a link to the picture, click Link ( changes to ).
· Click OK to add the picture to the record.
Tribute Electronics : ...
The cell displays information about the picture you added to the record. To add pictures to other records, repeat steps 1 to 9 starting on page 103 for each record.
Products : Table
12:00 PM
VIEW A PICTURE
⁄ To view a picture, double-click the cell containing the picture you want to view. Note: A warning dialog box may appear. Click Open to continue.
105
CREATE A LOOKUP COLUMN Product You can create a lookup column, which displays a list of values that you can choose from when entering information in a field.
Shipping Method
Victoria cutlery sets
FedEx
Open sign Henderson chairs
Speedy Delivery
Table decorations
Speedy Delivery
Ashley dish sets
Speedy Delivery
Oak tables
Speedy Delivery
Standard menus
Speedy Delivery
Blue napkins
Speedy Delivery
FedEx UPS Purolator
CREATE A LOOKUP COLUMN
Lookup Wizard...
Outdoor Sporting Go...
⁄ Click the Data Type area for the field you want to use a lookup column. An arrow ( ) appears.
106
Products : Table
12:00 PM
¤ Click the arrow (
)
to display a list of data types.
‹ Click Lookup Wizard.
Outdoor Sporting Go...
The Lookup Wizard appears.
› To type the values you want to appear in the lookup column, click this option ( changes to ).
Products : Table
12:00 PM
ˇ Click Next to continue.
Design Tables
Tip
Why would I create a lookup column?
STATE STATE AGE GROUP
Creating a lookup column is useful if you repeatedly enter the same values in a field. For example, if your customers reside in three states, you can create a lookup column that displays the three states, such as CA, TX and IL.
Outdoor Sporting Go...
Á Click this area and then type the first value you want to appear in the lookup column.
Products : Table
4
CA TX
0 - 15
IL
16 - 25 26 - 50
TITLE
Mr. Ms. Mrs.
12:00 PM
To adjust the width of the lookup column, position the mouse over the right edge of the column heading ( changes to ) and then drag the column edge to the width you want.
51 - 65 66 - 100
Outdoor Sporting Go...
‡ To enter the next value, press the Tab key and then type the value.
° Repeat step 7 for each
Products : Table
12:00 PM
· When you finish entering all the values for the lookup column, click Next to continue.
value you want to appear in the lookup column.
107
CREATE A LOOKUP COLUMN
Order ID When entering data in a field, you can select a value from a lookup column to save time.
Selecting a value from a lookup column can also prevent errors such as typing mistakes and ensure that you enter the correct type of data in a field.
Product
Company Name
Qty
Ship
1 Hungry Pete's
Victoria cutlery sets
3 Ground
2 The Friendly Diner
Open sign
2 1 Day Air
3 Vegetarian Cuisine
Henderson chairs
4 4 Day Air
4 The Hot Grill
Table decorations
20 4 Day Air
5 Healthy Foods
Ashley dish sets
1 Day Air 2 Ground
6 Mr. Steak
Oak tables
2 Day Air 5 Ground
7 Supper's Ready
Standard menus
1 Day Air 45 Ground 2 Day Air 4 Day Air
CREATE A LOOKUP COLUMN (CONTINUED)
Category Text
Outdoor Sporting Go...
‚ This area displays the name of the field that will offer the lookup column. To change the field name, type a new name.
108
Products : Table
12:00 PM
Outdoor Sporting Go...
— Click Finish to create
± Click
the lookup column.
changes.
to save your
Products : Table
12:00 PM
¡ To display your table in the Datasheet view, click .
Design Tables
Tip
Do I have to select a value from a lookup column?
Tip
No. If a lookup column does not display the value you want to use, you can type a different value. To hide a lookup column you displayed without selecting a value, click outside the lookup column. You can then type your own value. Order ID
Company Name
Product
Qty
Ground
2 The Friendly Diner Open sign
2
1 Day Air
3 Vegetarian Cuisine Henderson chairs
4 TNT Express
Victoria cutlery sets
If you want to change the values that a lookup column displays, you can recreate the lookup column. To recreate a lookup column, repeat the steps starting on page 106.
4 Day Air
4 The Hot Grill
Table decorations
20
5 Healthy Foods
Ashley dish sets
2
Ground
6 Mr. Steak
Oak tables
5
2 Day Air
7 Supper's Ready
Standard Menus
45
Can I change the values in a lookup column?
Ship
3
1 Hungry Pete's
4
Ground
Hiking
Hiking
Outdoor Sporting Go...
Products : Table
12:00 PM
USE A LOOKUP COLUMN
¤ Click the arrow (
⁄ To use a lookup column
to display the lookup column.
to enter data, click a cell in the field that offers the lookup column. An arrow ( ) appears.
)
Outdoor Sporting Go...
The value you selected appears in the cell.
Products : Table
To return to the Design view, click
12:00 PM
.
‹ Click the value you want to enter.
109
CREATE A YES/NO FIELD
You can create a field that accepts only one of two values––Yes/No, True/False or On/Off.
Student ID
Test 1 (60)
Test 2 (40)
Test 3 (40)
960001
50
25
35
Pass Yes
960002
56
30
28
Yes
960003
45
35
36
Yes
960004
54
22
38
Yes
960005
28
19
18
No
960006
50
26
40
Yes
960007
49
36
40
Yes
960008
15
20
19
No
For example, you can create a Yes/No field to specify whether each student passed a course. CREATE A YES/NO FIELD
Text
Yes/No
Outdoor Sporting Go...
⁄ Click the field you want to appear after the new Yes/No field. A triangle ( ) appears beside the field name.
Products : Table
To add a Yes/No field to the end of your table, click the area directly below the last field name. Then skip to step 3.
¤ Click
to add a field to your table.
110
12:00 PM
Outdoor Sporting Go...
An area appears where you can enter information for the new field.
‹ Type a unique name for the new field and then press the Enter key.
Products : Table
12:00 PM
› To select the data type for the new field, click the arrow ( ) in the Data Type area.
ˇ Click Yes/No.
Design Tables
Tip
4
How can I display data in a Yes/No field?
PASS
PASS
PASS
Yes No
Yes
No
No
Yes Check Box
Text Box
Combo Box
Displays a check box ( ). You can click the check box to indicate Yes ( ) or No ( ).
Displays a value, such as Yes or No. You can type the value you want to enter.
Displays a value, such as Yes or No. You can type the value you want to enter or click the arrow ( ) in a cell to select the value from a drop-down list.
Yes/No
Yes Combo Box
Outdoor Sporting Go...
Á To select a format for the field, click the area beside Format. An arrow ( ) appears. ‡ Click the arrow (
) to display the available formats.
Products : Table
12:00 PM
Outdoor Sporting Go...
Products : Table
12:00 PM
° Click the format you
‚ Click the area beside
± Click the display
want to use.
Display Control. An
option you want to use.
· To select the way you want data to appear in the field, click the Lookup tab.
arrow (
Note: You can click the General tab at any time to return to the General properties.
) appears.
— Click the arrow ( to display the available options.
)
Note: For information on the display options, see the top of this page.
111
CREATE A YES/NO FIELD Product Name
Product ID If you are creating a Yes/No field that uses a Combo Box, you can specify the values you want to appear in the drop-down list for the field.
In Stock
Discontinued
1001
Harrison Running Shoes
150
No
1002
Energy Bar
200
No
1003
Clear Water Bottle
525
No
1004
DVD Sunglasses
325
1005
The Ultimate Exercise Book
250
YesNo
1006
Reflective Jacket
50
No No
1007
Pedometer
60
Yes
s Value CREATE A YES/NO FIELD (CONTINUED)
Value List
Outdoor Sporting Go...
Products : Table
12:00 PM
¡ If you selected Combo Box in step 12, click the area beside Row Source Type. An arrow ( ) appears.
™ Click the arrow (
Note: If you selected Check Box or Text Box in step 12, skip to step 18.
be able to type the values you want to appear in the drop-down list for the field.
112
)
to display the available options.
£ Click Value List to
Outdoor Sporting Go...
¢ Click the area beside Row Source.
∞ Type the two values you want to appear in the drop-down list for the field. Separate the values with a semicolon (;).
Products : Table
12:00 PM
Note: The values you type should match the format you selected in step 8 on page 111.
Design Tables
Tip
How can I speed up entering data in a Yes/No field?
Why does the Property Update Options button ( ) appear when I create a Yes/No field?
Tip
When you add a new record to your table, Access automatically displays the No, False or Off value in a Yes/No field. The value Access displays depends on the format you selected in step 8 on page 111. If most of your records will require a Yes, True or On value, you can change the default value to Yes, True or On. To set the default value for a field, see page 91. Student ID
Last Name
Pass
990416
Abbott
Yes
992438
Barrow
No
993641
Clare
Yes
997695
Harris
Yes
4
You can use the Property Update Options button ( ) to automatically update the format of the Yes/No field in all your forms or reports that display the field. Click the Property Update Options button to display a list of options and then select the option you want to use. The Property Update Options button is available only until you perform another task.
Automatically Display:
Yes
1
Outdoor Sporting Go...
§ Click to save your changes.
Products : Table
¶ Click
to display your table in the Datasheet view.
12:00 PM
Outdoor Sporting Go...
The Yes/No field appears in your table.
Products : Table
To return to the Design view, click
12:00 PM
.
113
CREATE A HYPERLINK FIELD
You can create a field that allows you to add a hyperlink to each record in a table. A hyperlink, also called a link, allows you to quickly display a Web page or file or send an e-mail message.
Products Inc.
For example, you can create a Hyperlink field to store the Web page addresses or e-mail addresses of your suppliers. You can then select a hyperlink to quickly display a supplier's Web page or send the supplier an e-mail message. CREATE A HYPERLINK FIELD
Outdoor Sporting Go...
⁄ To create a field that will store hyperlinks, click the name of the field you want to appear after the new field. A triangle ( ) appears beside the field name.
114
Customers : Table
12:00 PM
To add a Hyperlink field to the end of your table, click the area directly below the last field name. Then skip to step 3.
Outdoor Sporting Go...
¤ Click
to add a field to your table.
Customers : Table
12:00 PM
A new row appears where you can enter information for the new field.
‹ Type a unique name for the field and then press the Enter key.
Design Tables
Tip
What types of files can I create hyperlinks to?
You can create hyperlinks to files such as documents, pictures, spreadsheets and sounds. When you select a hyperlink to a file, the appropriate program will open and display or play the file. To select a hyperlink to a file, see page 117.
Tip
Will the Hyperlink field I add to my table appear on a form?
When you create a form using a table that contains a Hyperlink field, the form will display the Hyperlink field. You can select a hyperlink on a form as you would select a hyperlink in a table. To select a hyperlink in a table, see page 117. TABLE
Dear member:
Company Name
ID
This year marks the Boston Cycling Club's first ever cycle-a-thon, which takes place April 10. The event is aimed at raising money for local charities while raising our organization's profile in the community.
1 Sports Inc. 2 Slam Dunk Inc. 3 J.J. Sports Wear
Prizes will be awarded to those who raise the most money. Sportz Inc.
Mark Williams SALES REPORT President, Boston Cycling January Club February Jim Mary Arthur Nancy
4
$51,000.00 $36,700.00 $30,200.00 $45,800.00
$45,600.00 $35,500.00 $25,500.00 $43,900.00
March $49,800.00 $40,100.00 $27,800.00 $44,000.00
$163,700
$150,500
$161,700
TOTAL SALES
Web Site www.sportsinc.com www.slamdunk.com www.jjsportswear.com
FORM Total Commission $146,400.00 $2,928.00 $112,300.00 $2,246.00 $ 83,500.00 $1,670.00 $133,700.00 $2,674.00 $475,900
Slam Dunk Inc.
Commission Rate 0.02
m www.slamdunk.co
Text
Hyperlink
Outdoor Sporting Go...
› To select the data type for the new field, click the arrow ( ) in the Data Type area.
Customers : Table
Á Click
12:00 PM
to save your
changes.
‡ Click
to display your table in the Datasheet view.
Outdoor Sporting Go...
The Hyperlink field appears in your table.
Customers : Table
12:00 PM
To return to the Design view, click .
Note: To add hyperlinks to the field, see pages 116 to 119.
ˇ Click Hyperlink.
115
CREATE A HYPERLINK FIELD
After you create a field that will store hyperlinks, you can add hyperlinks to the field that will allow you to quickly display Web pages or files stored on your computer, network, corporate intranet or the Internet.
Company ID
Company Name 1 Sports Inc. 2 Slam Dunk Inc.
Web Site www.sportsinc.com
3 J.J. Sports Wear 4 Total Sports Inc.
www.slamdunk.com www.jjsportswear.com www.totalsports.com
5 Racquets R Us
www.racquets.com
An intranet is a small version of the Internet within a company. CREATE A HYPERLINK TO A WEB PAGE OR FILE
Outdoor Sporting Go...
⁄ To create a hyperlink to a Web page or file, click the cell for the record you want to add the hyperlink to. Note: To create a field that will store hyperlinks, see page 114.
116
Customers : Table
¤ Click
12:00 PM
to add a
Outdoor Sporting Go...
‹ Click Existing File
Customers : Table
12:00 PM
hyperlink.
or Web Page to create
The Insert Hyperlink dialog box appears.
a hyperlink to an existing file or Web page.
To create a hyperlink to a file on your computer or network, click the file in this area.
› To create a hyperlink to a Web page, click this area and type the address of the Web page.
This area shows the location of the displayed files. You can click this area to change the location.
Design Tables
Tip
Is there a faster way to create a hyperlink to a Web page or file?
How do I remove a hyperlink to a Web page or file?
Tip
Yes. When you type the address of a Web page or the location and name of a file into a field that stores hyperlinks, Access will automatically change the address or location and name to a hyperlink for you.
www.maran.com
4
To select the hyperlink you want to remove, position the mouse over the left edge of the cell that contains the hyperlink ( changes to ) and then click to select the contents of the cell. To delete the hyperlink, press the Delete key.
ame
Web Site www.sportsinc.com
c. ar
www.slamdunk.com www.jjsportswear.com
nc.
www.totalsports.com
s
www.racquets.com Delete
Outdoor Sporting Go...
This area displays the text that will appear in the Hyperlink field.
ˇ To change the text, drag the mouse over the text until you highlight all the text. Then type the text you want to appear in the field.
Customers : Table
12:00 PM
Á Click OK to add the hyperlink to the field.
Outdoor Sporting Go...
Customers : Table
Access adds the hyperlink to the field. A hyperlink appears underlined and in color. When you position the mouse over a hyperlink, a yellow box appears, displaying the Web page address or the location and name of the file that the hyperlink will display.
12:00 PM
SELECT A HYPERLINK
⁄ To select a hyperlink to display the Web page or file connected to the hyperlink, click the hyperlink.
117
CREATE A HYPERLINK FIELD
After you create a field that will store hyperlinks, you can add hyperlinks to the field that will allow you to quickly send e-mail messages.
e Pric l e i Dan Bell a s Li arris H a s Lind one J d i g Dav oun Y t e Jan
om bc.c a a@ ielilnd .com n a d abc @ a lis
om m bc.c c.co a b a @ id t@ dav jane
CREATE A HYPERLINK TO AN E-MAIL ADDRESS
mailto:
[email protected]?subject=Outdoor Sport
mailto:
[email protected]
Outdoor Sporting Go...
⁄ To create a hyperlink to an e-mail address, click the cell for the record you want to add the hyperlink to. Note: To create a field that will store hyperlinks, see page 114.
118
Customers : Table
¤ Click
12:00 PM
to create
a hyperlink. The Insert Hyperlink dialog box appears.
Outdoor Sporting Go...
‹ Click E-mail Address
Customers : Table
12:00 PM
to create a hyperlink to an e-mail address.
Note: Access automatically adds mailto: to the beginning of the e-mail address you type.
› Click this area and type
ˇ If you want specific
the e-mail address of the person you want to receive the e-mail messages.
information to appear in the Subject area of the e-mail messages, click this area and type the subject.
Design Tables
Tip
Is there a faster way to create a hyperlink that will allow me to send e-mail messages?
Yes. In a field that stores hyperlinks, you can type mailto: followed by the e-mail address of the person you want to send messages to. For example, you can type mailto:
[email protected]. Access will automatically change the text you type to a hyperlink. mailto:
[email protected]
Tip
4
How do I remove a hyperlink to an e-mail address?
To select the hyperlink you want to remove, position the mouse over the left edge of the cell that contains the hyperlink ( changes to ) and then click to select the contents of the cell. To delete the hyperlink, press the Delete key.
act
E-mail Address
rice
[email protected]
orll
[email protected]
d is
[email protected]
n nes
[email protected]
ng
[email protected]
Delete
mailto:
[email protected]
mailto:
[email protected]
Outdoor Sporting Go...
This area displays the text that will appear in the Hyperlink field.
Á To change the text, drag the mouse over the text until you highlight all the text. Then type the text you want to appear in the field.
Customers : Table
12:00 PM
‡ Click OK to add the hyperlink to the field.
Outdoor Sporting Go...
Access adds the hyperlink to the field. A hyperlink appears underlined and in color.
Customers : Table
12:00 PM
SELECT A HYPERLINK
⁄ To select a hyperlink to send an e-mail message to a person, click the hyperlink. Your e-mail program will open, displaying a new message addressed to the person you specified.
119
USING SMART TAGS November
You can use smart tags to quickly perform tasks while working in Access. A smart tag is information, such as a date, which Access recognizes and labels.
4
3
2
2003
1
5
6
7
8
15
11
13
9
10
12
14
21
22
18
20
17
19
16
28
29
25
27
24
26
23
30
dar
y Calen Show m
wis Mar tin Miller Morris Nelson Price Reed Ross Smith
17/11/2
003 3 3
For example, you can have Access label dates in a field to allow you to quickly display your Microsoft Outlook calendar for a date of interest.
3 3 3 3 3 3
USING SMART TAGS
Date
Tribute Electronics...
Employees : Table
12:00 PM
SET UP A FIELD TO USE SMART TAGS
¤ Click the area beside
⁄ Click the field you
appears.
want to use smart tags.
‹ Click the button (
Smart Tags. A button (
) ).
Tribute Electronics...
The Smart Tags dialog box appears. This area displays the types of information Access can label as smart tags.
Employees : Table
12:00 PM
› You can click the check box beside a type of information to turn smart tags on ( ) or off ( ) for the information.
ˇ Click OK to confirm your changes. 120
Design Tables
Tip
4
What actions can I perform for data labeled with a smart tag? Date
Financial Symbol
Person’s Name
When a date in your table is labeled with a smart tag, you can display your Microsoft Outlook calendar or schedule a meeting for the date.
When a company’s financial symbol in your table is labeled with a smart tag, you can get a stock price or display information about the company, such as a company report or a recent news item.
When a person’s name or e-mail address is labeled with a smart tag in your table, you can send the person an e-mail message, schedule a meeting with the person, view the person’s contact information or add the person to your list of contacts in Microsoft Outlook.
Address
Date
9 Beach St.
12/23/2003
0 Pine St.
4/21/2004
Westside St.
11/07/2003
Mill St.
10/20/2003
C
Company Name
Financial Symbol
Name
MSFT
9 Beach St.
Erin Baker
Intel Corporation
INTC
0 Pine St.
Paul Fraser
Westside St.
Ryan Smith
Mill St.
Mary Wilson
Coca-Cola Bottling Co. COKE August 2004
Address
Microsoft Corporation
Hershey Foods Corp.
HSY
USA 29
Linda Frank David Nancy Stacy Ann Amy Sara Diane Josh Daniel Helen Emily
Tribute Electronics...
This area displays information about the smart tags you selected.
Employees : Table
Á Click changes.
12:00 PM
to save your
‡ Click to display your table in the Datasheet view.
Harris Hill Jones King Lee Lewis Martin Miller Morris Nelson Price Reed Ross
Tribute Electronics...
Employees : Table
USE A SMART TAG
A purple triangle appears in the bottom right corner of a cell containing data that Access labels with a smart tag.
⁄ To perform an action using a smart tag, click a cell containing a purple triangle.
12:00 PM
The Smart Tag Actions button ( ) appears.
¤ Click the button to display a list of actions you can perform using the smart tag.
‹ Click the action you want to perform.
121
Net y ID ompan
C
1001 1002 1003 1004 1005
1006 1007 1008
No
Check Check Check
s 30 day s 60 day s 30 day s y a 45 d s y 30 da s 90 day s 30 day s y a 30 d
No No Yes Yes
Check Check
No Yes
Check Check Check
Pro
ducts
Table
e
U
am uct N
Prod r kit repai
uct ID Bike 6400 suit Wet 1 0 tick 64 sse s o r c a L all 6402 footb r e h Leat 6403 oard kateb S 6404 ggles ki go S 6405 oard nowb S 6406 oard Surfb 7 640 stand -ball T 6408 ball olley V 6409
Prod
ADDRESS
ES Table
Company ID
Company
N
ame 1001 Ree l Fishing 1002 Ath letics Inco rporated 1003 Ou ter World
Address
76 Haverly
City
Lane Los A ngeles 850 Grand St. Gree
State/Prov
CA
ince Pos tal
9001
CHAPTER 5
Establish Relationships Do you want to establish relationships between the tables in your database? This chapter teaches you how. ed ntinu No
Price
Unit 5 $34.9 .95 $389 5 $39.9
No
100
No
1000 1500
No
0 $29.5 5 $54.9
500
No
700
No
9 $29.9 0 210.5
150
No
100
No
.99 $499 5 $19.9
100
No
$
5
$29.9
stal Code
1
isco ck D o t S in Units 550
750
No
View Object Dependencies ..............124 Set the Primary Key ........................126 Create Relationships Between Tables ..........................................128 Enforce Referential Integrity ..............132
VIEW OBJECT DEPENDENCIES
You can view a list of objects, such as tables, forms, queries and reports, that depend on a specific object in your database. This allows you to quickly see which items require data from an object of interest.
Depends on: Products Table
For example, if you are considering deleting a table from your database, you may want to first view a list of the objects that depend on the table. If other objects depend on the table, you should not delete the table.
VIEW OBJECT DEPENDENCIES
Orders
Orders
Tribute Electronics: ...
⁄ In the Database window, click the type of object you want to view dependencies for.
124
12:00 PM
¤ Click the object you want to view dependencies for. Note: You cannot view dependency information for data access pages in your database. For information on data access pages, see pages 280 to 295.
Tribute Electronics: ...
‹ Click View.
12:00 PM
› Click Object Dependencies.
Establish Relationships
Tip
Why does this dialog box appear when I view object dependencies in my database?
Tip
The first time you view dependency information for a database, Access must first gather and update the dependency information. Click OK in the dialog box to continue.
The Object Dependencies task pane appears.
Can I view a list of tables, forms, queries and reports that contain data required by an object of interest?
Yes. For example, you can quickly view a list of tables that contain data required by a form of interest. Perform steps 1 to 6 below, except select Objects that I depend on in step 5.
Orders
Orders
Tribute Electronics: ...
5
12:00 PM
ˇ Click Objects that depend on me to view
objects that require data stored in the object you selected ( changes to ).
Tribute Electronics: ...
This area displays the objects of interest. To quickly open an object displayed in the task pane, click the name of the object.
12:00 PM
To view dependency information for another object in the database, repeat steps 1 to 4.
Á When you finish viewing dependency information, click to close the Object Dependencies task pane. 125
SET THE PRIMARY KEY
# Social Security
You can set the primary key for a table. A primary key is one or more fields that uniquely identifies each record in a table. Each table in your database should have a primary key.
Position
111-11-1111
Assistant
222-22-2222
Secretary
333-33-3333
Editor
444-44-4444
Sales Rep
600-60-6000
Designer
777-77-7777
Sales Rep
888-88-8888
Editor
999-99-9999
Writer
Hours Per Week
Salary
$25,000
40
$30,000
40
$28,000
35
$75,000
38
$39,000
38
$42,000
40
$32,000
42
$50,000
44
Access uses the primary key in each table to create relationships between the tables in your database. Relationships between tables allow Access to bring together related information in the tables. For information on relationships, see page 128.
SET THE PRIMARY KEY
All Stars Sports Ltd...
Customers : Table
12:00 PM
⁄ Display the table you want to change in the Design view. To change the view of a table, see page 74.
Note: You may have had Access set a primary key for you when you created the table.
The field that is currently set as the primary key displays a key symbol ( ).
¤ Click the name
126
of the field you want to set as the primary key.
All Stars Sports Ltd...
‹ Click to set the field as the primary key. A key symbol ( ) appears beside the field.
Customers : Table
› Click change.
12:00 PM
to save your
Establish Relationships
Tip
5
What types of primary keys can I create?
ID
Invoice #
Last Name
Date of Birth
1
6218
Abbott
6/19/1970
2
7410
Smith
3/1/1967
3
8611
Smith
12/18/1980
4
9431
Turner
2/5/1954
AutoNumber
Single-Field
Multiple-Field
A field that automatically assigns a unique number to each record you add. When you create a table, Access can create an AutoNumber primary key for you.
A field that contains a unique value for each record, such as an invoice number, social security number or product number.
Two or more fields that together make up a unique value for each record, such as a last name and date of birth.
Company Name Billing Address
All Stars Sports Ltd...
Access sets the Indexed property of the field to Yes (No Duplicates). Access will index the data in the field so you can quickly sort and search for data in the field.
Customers : Table
12:00 PM
The phrase No Duplicates indicates that Access will not allow you to enter the same value more than once in the field.
Text Text
All Stars Sports Ltd...
Customers : Table
CREATE A MULTIPLE-FIELD PRIMARY KEY
⁄ To set more than one field as the primary key, press and hold down the Ctrl key as you click the area to the left of each field you want to set as the primary key.
12:00 PM
¤ Click to set the selected fields as the primary key. A key symbol ( ) appears beside each field.
127
CREATE RELATIONSHIPS BETWEEN TABLES
You can create relationships between tables. Relationships between tables allow you to bring together related information in your database.
Relationships between tables are essential for creating a form, query or report that uses information from more than one table in your database. CREATE RELATIONSHIPS BETWEEN TABLES
Create table in Design view
Customers
Tribute Electronics : ...
⁄ Click to display the Relationships window.
12:00 PM
Note: If is not available, press the F11 key to display the Database window and toolbar.
Tribute Electronics : ...
Relationships
The Relationships window appears. If any relationships exist between the tables in your database, a box for each table appears in the window. The Show Table dialog box may also appear, listing all the tables in your database.
128
12:00 PM
¤ If the Show Table dialog box does not appear, click to display the dialog box.
Establish Relationships
Tip
Why do relationships already exist between the tables in my database?
If you used the Database Wizard to create your database, the wizard automatically created relationships between the tables for you. For information on the Database Wizard, see page 10. Customers Table
Tip
5
How do I remove a table from the Relationships window?
To remove a table from the Relationships window, click the box for the table and then press the Delete key. Removing a table from the Relationships window will not delete the table from your database or affect the table's relationships with other tables.
Orders Table
Inventory Table
Delete
OrderID
OrderID
Orders
Tribute Electronics : ...
‹ To add a table to the Relationships window, click the table you want to add. › Click Add to add the table to the window.
Relationships
12:00 PM
ˇ Repeat steps 3 and 4 for each table you want to add. Á When you finish adding tables to the Relationships window, click Close to remove the Show Table dialog box.
Tribute Electronics : ...
Each box in the Relationships window displays the fields for one table.
Relationships
12:00 PM
The primary key in each table appears in bold. The primary key uniquely identifies each record in a table.
129
CREATE RELATIONSHIPS BETWEEN TABLES
You create a relationship between tables in your database by identifying the matching fields in the tables.
COMPANY ADDRESSES Company ID
Company Name
Address
ORDERS City
1 Pet Superstore
258 Linton Ave.
2 Petterson Inc.
50 Brittania Lane Boston
State
Order ID Company ID
NY
1001
Product
You will usually relate the primary key in one table to a matching field in the other table. In most cases, the fields will have the same name.
Quantity Unit Price
MA
1002
4 Vitamins 2 Bulk Dry Food
15
$18.00
3 Martin Vet Supplies 68 Cracker Ave.
San Francisco CA
1003
8 Diet Dog Food
30
$10.00
4 Greg’s Pet Store
47 Crosby Ave.
Las Vegas
NV
1004
1 5-Variety Biscuits
50
$3.50
5 Dogs R Us
26 Arnold Cres.
Jacksonville
FL
1005
3 Canned Dog Food
24
$3.00
6 Feline Foods Inc.
401 Idon Dr.
Nashville
TN
1006
6 Dry Cat Food
40
$4.00
7 Weasels R Us
1320 1st Rd.
Atlanta
GA
1007
7 Ferret Pellets
30
$6.50
Boston
MA
1008
5 Dry Cat Food
24
$4.00
8 Purrrrfect Portions 36 Buzzard St.
New York
12
$20.00
The fields you use to create a relationship between tables should contain the same type of data, such as text, numbers or dates. CREATE RELATIONSHIPS BETWEEN TABLES (CONTINUED)
CustomerID
CustomerID
Tribute Electronics : ...
‡ To create a relationship between two tables, position the mouse over a field you want to use to create the relationship.
130
Relationships
12:00 PM
° Drag the field to the matching field in the other table.
Tribute Electronics : ...
The Edit Relationships dialog box appears. This area displays the names of the tables you are creating a relationship between and the names of the matching fields.
Relationships
12:00 PM
This area displays the type of relationship. For information on the types of relationships, see the top of page 131.
· Click Create to create the relationship.
Establish Relationships
Tip
5
What types of relationships can I create between tables? s
Credit Record Customers Social Security
ID
First Name
111-11-1111
Ryan
222-22-2222
Erin
333-33-3333
Josh
444-44-4444
Carl
600-60-6000
Emily
777-77-7777
Sue
888-88-8888
Jack
999-99-9999
Paul
Last Name
Social Security
City
Address
Smith
York 258 Linton Ave. New
Baker
50 Tree Lane
Nelson
San Francisco 68 Cracker Ave.
Davis
Las Vegas 47 Crosby Ave.
Ross
26 Arnold Cres.
Boston
Jacksonville
401 Idon Dr.
Nashville
Adams
10 Heldon St.
Atlanta
Fraser
36 Buzzard St.
Grant
ID
111-11-1111
Line of Credit
$7,500
222-22-2222
$10,000
333-33-3333
$500
444-44-4444
$5,000
600-60-6000
$2,000
777-77-7777
$1,000
888-88-8888 999-99-9999
City
Credit Available Balance Owing
Customers
$5,000
$2,500
$1,250
$8,750
Customer ID
$235
$265
111-11-1111
$4,500
$500
$1,900
$100
$900
$100
$2,500
$200
$2,300
$10,000
$9,200
$800
Boston
1
First Name Ryan
Last Name Smith
City
Address
Order ID 1001
New York 258 Linton Ave.
1002 1003
2
Erin
Baker
50 Tree Lane
Boston
1004 1005
3
Josh
Nelson
68 Cracker Ave.
San Francisco
1006 1007
4
Carl
Davis
Las Vegas 47 Crosby Ave.
1008
Orders Customer ID
1
1
1 1 3-3333 333-31 2
444-44-4444
Product Name
Cost
Shoes
$35
Skates
$45
Gloves
$15
Hat
$25 $150
2
Skis
3
Glasses
3
Putter
$125
Helmet
$90
600-60-6000 777-77-7777 888-88-8888
4
4-44494 999-99-999 444-4
$10
Quantity 1 1 3 1 1 4 1 1
999-99-9999
One-to-One
One-to-Many
Each record in a table relates to one record in another table. For example, each customer has only one credit record. Access creates a one-to-one relationship between tables if the matching fields are both primary keys.
Each record in a table relates to one or more records in another table. This is the most common type of relationship. For example, each customer can have more than one order. Access creates a one-to-many relationship between tables if only one of the matching fields is a primary key.
Tribute Electronics : ...
Relationships
12:00 PM
A line connects the fields in the two tables to show the relationship.
— Click
‚ To create a relationship
working in the Relationships window, click to close the window.
between other tables in your database, repeat steps 7 to 9 for each relationship you want to create.
Tribute Electronics : ...
to save your changes.
DELETE A RELATIONSHIP
± When you finish
window, click the line for the relationship you want to delete.
⁄ In the Relationships
¤ To delete the relationship, press the Delete key.
Relationships
12:00 PM
A confirmation dialog box appears.
‹ Click Yes to permanently delete the relationship.
131
ENFORCE REFERENTIAL INTEGRITY
Referential integrity is a set of rules that prevents you from changing or deleting a record if matching records exist in a related table.
For example, you cannot delete a customer from the Customers table if the related Orders table contains orders for the customer.
ORDERS TABLE Order #
Product
Qty
12340
1 Sport City
Water Bottle
30
$3.50
13609
1 Sport City
Tennis Balls
30
$8.00
13400
2 Racquets & Stuff
Tennis Balls
15
$18.00
3 Pet Superstore
Vitamins
12
$20.00
15309
ID
Company Name
CUSTOMERSS TABLE Company Name
Unit Price
C
$
ID
Address
3
68 Cracker Ave Ave.
San Francisco CA
94110
Outdoor Wilderness Inc. 2
258 Linton Ave.
New York
NY
10010
Racquets & Stuff
3
50 Brittania Lane
Boston
MA
Greg’s Pet Store
4 47 Crosby Ave
Las Vegas
NV
Sport City
Referential integrity also prevents you from entering a record in one table if a matching record does not exist in a related table. For example, if a customer does not exist in the Customers table, you cannot enter an order for the customer in the Orders table.
City
State Postal Code
02117 89116
ENFORCE REFERENTIAL INTEGRITY
Create table in Design view OrderID
12:00 PM
Tribute Electronics : ...
⁄ Click to display the Relationships window.
Note: If is not available, press the F11 key to display the Database window and toolbar. The Relationships window appears.
132
Tribute Electronics : ...
¤ To enforce referential integrity between two tables in your database, double-click the line showing the relationship between the tables.
Relationships
12:00 PM
Note: If a line does not appear between the tables, you must create a relationship between the tables. To create a relationship, see page 128. The Edit Relationships dialog box appears.
Establish Relationships
Tip
5
How can I change or delete a record after I enforce referential integrity between two tables?
Access provides two options that allow you to perform updating and deleting tasks that would normally be prevented by referential integrity. Customers
Customers Customer ID
Customer ID
3
Orders
Orders 3
5
5 5 3
3
3
Cascade Update Related Fields
Cascade Delete Related Records
When you change data in the primary key in a table, Access automatically updates the matching data in the related table(s). For example, if you change a customer ID in the Customers table, the customer ID will automatically change for all the customer's orders in the Orders table.
When you delete a record in a table, Access automatically deletes matching records in the related table(s). For example, if you delete a customer from the Customers table, all the customer's orders will automatically be deleted from the Orders table.
Tribute Electronics : ...
Relationships
12:00 PM
‹ Click this option to enforce referential integrity between the tables ( changes to ).
Note: For more information on the options, see the top of this page.
› To have Access automatically update related fields or delete related records in the tables, click each option you want to use ( changes to ).
ˇ Click OK to confirm your changes.
Tribute Electronics : ...
When you enforce referential integrity between two tables, the line showing the relationship between the tables becomes thicker.
Relationships
12:00 PM
The symbols above the line indicate the type of relationship. In this example, each record in the Customers table (1) relates to one or more records in the Orders table ( ). Note: For information on the types of relationships, see the top 133 of page 131.
Datasheet Columnar
Tabular
1
Whic
h Sty
Which
Specify a Name
le?
t?
Layou
CHAPTER 6
PivotChart PivotTable
Create Forms Would you like to use forms to work with data in your database? In this chapter, you will learn how to create forms to help you present data in an organized, easy-to-use format. Create a Form Using an AutoForm ....136 Create a Form Using the Form Wizard ........................................138 Open a Form..................................144 Move Through Records ....................145 Edit Data ........................................146 Add a Record ................................148 Delete a Record ..............................149
Wh to In ich Fie clud lds e?
CREATE A FORM USING AN AUTOFORM
AutoForm You can use the AutoForm Wizard to quickly create a form that displays the information from one table in your database.
Customer ID
First Name
1 Ryan 2 Erin
Last Name
Address
City
258 Linton Ave. New York Boston 50 Tree Lane
Smith Baker
State/Province Postal Code
NY
3 Josh
Nelson
4 Carl
Davis
MA 68 Cracker Ave. San Francisco CA NV 47 Crosby Ave. Las Vegas
5 Emily
Ross
26 Arnold Cres. Jacksonville
6 Sue
Grant
401 Idon Dr.
Nashville
10010 02117
FL
94110 89116 32256
TN
37243
Emily
A form presents data from a table in an attractive, easy-to-use format. You can use a form to view, enter and change data in a table.
Ross
CREATE A FORM USING AN AUTOFORM
AutoForm: Columnar Create form in Design view
Customers
12:00 PM
Outdoor Sporting Go...
⁄ Click Forms in the Database window.
¤ Click New to create
‹ Click the type of
› Click
a new form.
AutoForm you want to create.
ˇ Click the table that contains
The New Form dialog box appears.
136
12:00 PM
Outdoor Sporting Go...
Note: For information on the types of AutoForms, see the top of page 137.
to display a list of the tables in your database. the information you want to display on your form.
Á Click OK to create your form.
Create Forms
Tip
6
What types of AutoForms can I create? Columnar
Tabular
Displays one record at a time.
Displays many records at a time.
1
Datasheet
PivotTable
PivotChart
Displays many records at a time and resembles a table in the Datasheet view.
Allows you to summarize and analyze data.
Allows you to display a graphical summary of data.
1
Outdoor Sporting Go...
The form appears. In this example, the form displays the field names from the table you selected and the data for the first record.
Customers
12:00 PM
Note: If you selected PivotTable or PivotChart in step 3, the PivotTable or PivotChart initially appears empty so you must add the fields you want to display. For information on using the PivotTable or PivotChart, see pages 232 and 238.
‡ Click
to save your form.
Outdoor Sporting Go...
The Save As dialog box appears.
° Type a name for your form and then press the Enter key.
Customers
12:00 PM
· When you finish reviewing the form, click to close the form.
137
CREATE A FORM USING THE FORM WIZARD
You can use the Form Wizard to create a form that displays information from one or more tables in your database. The wizard asks you a series of questions and then sets up a form based on your answers. Whic
h Sty
W
le?
yout ? hich La
Wh to In ich Fie clud lds e?
Specify a Name
Forms present data from tables in an attractive, easy-to-use format. You can use forms to view, enter and change data in tables. CREATE A FORM USING THE FORM WIZARD
Create form by using wizard
12:00 PM
Tribute Electronics : ...
⁄ Click Forms in the Database window.
138
Table: Customers
¤ Double-click Create form by using wizard.
Tribute Electronics : ...
The Form Wizard appears.
‹ Click
in this area to select the table that contains the fields you want to include on your form.
12:00 PM
› Click the table that contains the fields.
Create Forms
Which tables in my database can I use to create a form?
Tip
6
In what order will the fields I select appear on my form?
Tip
You can use any table in your database to create a form. When creating a form that uses information from more than one table, relationships must exist between the tables so Access can bring together the information in the tables. For information on relationships, see page 128.
When you select fields in the Form Wizard, the order in which you select the fields determines the order in which the fields will appear on your form. Make sure you select the fields in the order you want them to appear on your form.
8
l Code stade l Co Po de cestaPo Procevin stal Co Prote/vin te/Sta 0ce010Po 10 l Code vin 1001 Posta y Sta te/Pro de 7 ce010 City Cit 10 7 11vin NY Sta 0211 stal Co Pro de 010Po State/02 rk CitNYy ssdress 710ce stal Co 11vin YowrkYo AddreAd 0Pro MAy NY 0 11te/02 ce0 Po Sta Nee.wssNe MA Cit vin01 dre e. Av 11710 941194 t Name NY Av tonAd 02Pro Name w York n y te/ 0 t Las 0 Lin ton ss Ne Cit 8 sto MA 11 n Sta Las Lin e. dre 6 25 Bo 7 1001 8 me stoAv York me 6 1194 BoAd NY t Na 00211 sco nCAw CA rk MA 89Cit11y89 ithLas25 NastmeNa ne e.ssNe nci e8LaLinneton nnci sto sco me 7 dre La25 Av 69411 Bo Fra Tre FirstFir eNa Scithhm Yo Ad hm NY t 11 CA me ton w 6 50 Fra ID Tre Sc 89 Sa n 0 0211 Na Las n ne Ne NV ss 6 25 IDss MA e.Lin 8La sto Sa ith e. sco n 50 ssdre NVdre First nci me eAv Bo e.r25 Av 32Yo25rk32 rsohm Ad 1169411 Tre Sc tAvNa r cke ttenme ton n Fra AddreAd Na rso ne 50 ID nNewCA Las Sagas sco Ve cke Cra Lin MA 110 gas La 25689 Jimss1 Jim NV 8 e. sto e. nci e PeFirttestPe 94 3 68ith Ve Cra me 32 hm n Las 6 Av 25 Bo Av FL 24 Fra Tre Na r Sc 3 68 11 CA Ad1dre assndJim me rso te. Las nton FL 50 IDa cke Av tte Sa gas ne e.Las lle Lin 25689 37n2437 sco t Na NV ithCra e.8Ve La sby bostPe n68Av lle Bre1 e25nvi dre t Fir Av hm r Las sby Cro nvi Ad2nd kso 116 Scme FLBoncisto sco 24332 n Fra 2 Bre cke e.Tre 47rso Tal Cro gas Jac Na 50 ID 5 CA a boTal Sane Av Pe Ve Cra 256 89 s.kso ith ndJim lleTN NV Jac 5 3737 t sttte Fir47 ee.La 30 TN sby nvi dre1ss Cre s.n68 hm Av r Las 24332 Fra37nci Tre 2dBre Sc rso Cro e.kso old d Ad aIDanTalbo 26tPeold cke 50 tte47Cre ille gasnFL30 Jim Jac lle 256 1ndssDe Cra ille shvAv TNSa s. 37537 sby 3 Tod3 Tod 2dAdBre Arn Arn De nNa 8 NV drean Ave.Ve 68 shv Las Cre r nvi Talbo Cro 26 FL 243 32 8 1130 Narso e.ksoGA 02
tteold 47 aJim 11 Jac an GA Av illecke Dr. TN Ve nd1Deson 02gas Cra s.shv 3 Tod Arn 37537 bin son Dr.t nPe Chuck nville 3 68 Bre 26 Ido asby Na d Ro 11830 e.GALas antCre old aCro Ro2bin 4 Ch4uck 40Tal1nbo 0 FL a Ido ille 1an 47Atl Jac Avkso 5 3724 ant 3 Tod De nd Dr. son 0lle0202 TN s. MA shv ntArn sby 26 nvi10 bo bin40 Na St.Atl Cre 1002 esBre ie4lanChieuck Hu aMA Cro 1183037 GA St.1TalnIdo esghd2Ro 47 ann40ldo Jackso ille noldant 5 son Dr.Atl 3ghTod He s.MA 02002 ldo sto 5 Me5lanMe Hu 26 ie uck He10De 1 TN BonArn 8 3037 Na sto aCreshv Ro 4 Ch St. d bin 1nIdo es 1 1210 GA Bo antNY an St. gh10 1292 Atl ldo nNYold 3HusTod son Dr. Arn De 0200211 rd40 5 Melan Ch MA 92ille St. He pin iesuck sto bin Susan 26nrk rd10zza Yo St. aNashv Bo Ro 4pin Top 118 zzaBu 12110 Yo1wnrkIdo 2 GA 6 Su6san Bu36es Toplan Ne ldo n antNY St. 5 Me Atl son Hus gh 2 0392 020 02 36 CA uck MA NeHe n Dr. rdw40 bin ieChpin CArksto Bo zza Ido 90a0390 St. ny Pl.10 NY lan4Top 6 Susan 5 Kil esRo 1 Yo 12110 en n Bu ant w zo go ny Pl. ken gh 40 92 Me St. 0 2 All ldo 36 en n Atl Ne s Biz 7 zo Hu Die 03 go rd ken n pin 15 7 MA 2 121 1002 Kilsan 7 All zza Die SaHe BoSt.rkstoCA CA 6 Su n10 Bu 15 Top 7 3690 NY nyieBiz Pl. w nYo CA en gh Me zoSaes Ne St. ldo go kenlan es St. Hu 30n3630 sBiz36 rdHe san CA Die 9003 92 gel rcu5Kilson es St. son ple rksto pin gGre7g All Maen6rcu n Su zza 10 15 An 7 Bo Ap gel Ma Yo 8 ny Pl. ple Sa s NY CA Bu Gre Top 12 0 36 w An Ap 0 zo Lo 8 go 2 92 1 89 NeSt. 0ken se.36 Biz Kilson esGA St. 7g All 0 2130 Lo rd 89 CA Av n Die e.15pin gel 79003 Susan zza ple ge SaGA 90Yo21rk90 An Bu Ap Top 8onGre ge 0Av rtin6Marcu Go zo 36 a sPl. ken 03036 NegowCA Lo Allen Go es St. 89ulany son ula 032 Ma Biz Kil e. 21 Die ant CA GA a 9 90 18 gel rcu 9 Jas9onJas 8onGre ple n Av 90 15 Ma7grtin Atl 7 03 ant An 9 Sa 18 CA Ma CA geAp 90 Atl 0ny sen zos Pl. Lo ken e.ula Allrtin 90 lsaCA ew e.Biz St. 2103036 Go GA Kil 9 Jas Av89 Die03go gs7Ma Hil lspleant ewtth gelnes rcu 15 18e.tson lyAv Av Gre geHil tLen 03990 ApAtl 367 8tthMa 0 CA CASa ly0ver s An 10 Jim 9 Jas Maon ula 90 30 s11Ma Len 97 rtin Be 0 Lo 0 a ver CA 89 10 Jim Go es St. e. son 01 ls ew e. 21 g 11 Ma 97 GA Be 18 Avant Hil rcu tth ple een 01 ts.Av Atl 03990 Angel lyCA s.Len Cre ge Ap f Gre een es 0 es ver 10thlJim tof ula Cre thlKa 0 f tofon8Ma erl Jas 89gel e.Be 11yMa 97090 gel y srtin lsaLosCA ew Go s An Ov 01GA An Hil ttherlMa ante.CA ts.Av Lo Ra9 Ra 11 Ka11 s18 ly Av Jim Atl 039 9021 esMA Lo on Cre thleen verge f Ov4 St. ula s11 gel St. y Len rtin Ka10 tof4Ma CAa CA e.BeMA An ultJas ew 0197090 Maerl s Go Ov s.t Av 18 ultyfa9Ra n Ro11n 4llow Witth lyAtlHilantls lem Jim 039 MA llow Th CreLo thl yfaeen CA veres Wi13fMa lem sSay Len Th10 11 12 Ro12 erlSt. AnBe e.gel Sa Ra 11n Ka 01970 90 ulttof Ovew St. Los.ts Av llow MAly HilCAls yfa13 een Jim es Ma Wi4tth Len Cre lfe futh 10Th 12nRo 11 So gelver ylem Sa11 13St. St. Kathl tof CA ult6uth 13nJoh 01970 48Ra 6yfaSo Overl WonlfeWo llow Los.s AnBe gelMA 13 Joh 48 es Theen fWi4St. el12n Ro an Salem y Cre 13 an Kalfethl tofuth So St. n11Wo llow chaMiel13chaJoh Ba12tem Batem 4 Overl Salem Los An yfa48ult6Ra So13uthWiSt. MA 14 Mi14 el n Ro temnWo St. anlfeTh 13 chaJoh 48 yfa6ult WiSt.llow lem Th nBaRo uth 12 liseDe14liseMi lfe el Sa 13 an So Joh 15 De Wo cha 486 15 Ba liseMi13 14 n tem uth St. Wolfe 15 De 13 elJoh 486 So teman liseMicha el Ba an 15 De14 Batem lise Micha 15 De 14 lise 15 De
Selected Fields:
LES TAB
Fax Number State
ID
Discount UnitPrice
Tribute Electronics : ...
This area displays the fields from the table you selected.
ˇ Double-click each field you want to include on your form.
12:00 PM
Note: To add all the fields from the table at once, click .
Tribute Electronics : ...
Each field you select appears in this area.
Á To remove a field you accidentally selected, double-click the field in this area. Note: To remove all the fields at once, click .
12:00 PM
‡ To include fields from other tables in your database, repeat steps 3 to 5 for each table. ° Click Next to continue.
139
CREATE A FORM USING THE FORM WIZARD
When creating a form that uses data from more than one table, you can choose the way you want to view the data on the form.
View Data Separately
View Data Together
You can choose to view the data from each table separately or together on a form. CREATE A FORM USING THE FORM WIZARD (CONTINUED)
by Customers
by Customers
Tribute Electronics : ...
12:00 PM
If you selected fields from more than one table, you can select the way you want to view the data on your form.
· Click the way you want to view the data on your form. You can view the data from each table separately or together.
Note: If this screen does not appear, skip to step 12.
This area displays the way the data will appear on your form.
140
Tribute Electronics : ...
‚ Click an option to specify if you want to create a form with a subform or a linked form ( changes to ). For more information, see the top of page 141. Note: If you selected to view the data from each table together in step 9, these options are not available.
12:00 PM
This area displays the way the data will appear.
— Click Next to continue.
Create Forms
Tip
6
How can I organize the data from multiple tables on a form?
If you choose to view the data from each table separately on a form, the Form Wizard offers two ways that you can organize data on the form.
Form
Form
Subform
Linked Form
Form with subform(s)
Linked forms
The data from each table appears in one window.
The data from each table appears in separate windows. You can click a button on the form to view the data on the linked form.
Tribute Electronics : ...
± Click the layout you want to use for your form or subform ( changes to ). For information on the available layouts, see the top of page 137.
12:00 PM
Note: The available layout options depend on the selections you made in steps 9 and 10. If this screen does not appear, skip to step 14.
Tribute Electronics : ...
This area displays a sample of the layout you selected.
¡ Click Next to continue.
12:00 PM
You can click Back at any time to return to a previous step and change your selections.
141
r pe
na
ce pa
tio
Ri
In ter na
You can choose the style you want your form to display. Access provides several styles, such as Blends, International and Ricepaper.
l
Bl en ds
CREATE A FORM USING THE FORM WIZARD
You may want to use the same style for every form in your database to give the database a consistent appearance. CREATE A FORM USING THE FORM WIZARD (CONTINUED)
International
Tribute Electronics : ...
™ Click the style you want your form to display. This area displays a sample of the style you selected.
142
12:00 PM
£ Click Next to continue.
Tribute Electronics : ...
¢ Type a name for your form. ∞ If your form includes fields from more than one table, you can also specify a name for your subform or linked form. To specify a name, press the Tab key and then type a name for the subform or linked form.
12:00 PM
Note: If you selected to view the data from each table together in step 9, you do not need to perform step 17.
Create Forms
Tip
How will my new form appear in the Database window?
Tip
The name of every form you create will appear in the Database window. If you created a form with a subform or a linked form, the subform or linked form will also appear in the Database window. You must open the main form to work with the contents of both the main form and the subform or linked form.
Create form in Design View Create form by using wizard Suppliers Products Linked Form Customers
6
How do I move through the information in a subform?
When you move through the information in the main form, the information in the subform automatically changes. For example, when you display the name and address of a customer, Access automatically displays the orders for the customer in the subform. To move through records in a form, see page 145.
Customers ith Last Name Sm Tree St. 56 Address New York City NY State
Orders Subform
Customers
Form
Suppliers
Orders Subform AD3
H SU P
y ice Quantit Orders Product Pr Last Name dio $99 12 Ra Smith
Products Linked Form
Subform
8
12:00 PM
Tribute Electronics : ...
§ Click this option to open the form so you can review and enter information in the form ( changes to ).
¶ Click Finish to create your form.
Tribute Electronics : ...
The form appears. Note: The appearance of your form depends on the options you selected while creating the form.
Customers
12:00 PM
In this example, the form displays the information for one customer on the main form and the orders for the customer in the subform.
• When you finish reviewing the form, click the form.
to close
143
OPEN A FORM
You can open a form to display its contents on your screen. Opening a form allows you to review and make changes to the form.
O R D E R S Order ID
6 15-Jan-02
Order Date Expected Shipment Shipment Method
16-Jan-02 Express
Comments Terms Customer ID
MMM FOOORRRR M S F FF O TTNSTSG UUUPCCC D I D D O PPPRRSROHOI P
Contact
F O R M Billing Address
890 Apple St.
City State/Province Postal Code
San Diego
Country
USA
Phone Number
(619) 555-2508
CA 92121
C.O.D. 401 Jim Martin
66 6 43 4343 t ID uc t ID od uct ID ucod odPr PrPr e t Na mem me uc t Na od uct Na ucod odPr PrPr ice it Pr ice Pr it Price it Un UnUn nyny mpa nypa Co pa m m Co Co ntor yntyory or Inve ntve In Inve
us eee ll Ho Ho llusHous ll Do DoDo 36 0.00.00 .036 36$4 $4$4 Inc.Inc. y c. ToIn r y te To as MM terasteyr To Mas
MS
FOR
0000 0010 1010
OPEN A FORM
1 Customers
12:00 PM
Tribute Electronics : ...
⁄ Click Forms in the Database window.
This area displays a list of the forms in your database.
The form opens. You can now review and make changes to the form.
¤ Double-click the form
When you finish working with the form, click to close the form.
you want to open.
144
Tribute Electronics : ...
Customers
12:00 PM
Note: A dialog box will appear if you did not save changes you made to the design of the form. Click Yes or No to specify if you want to save the changes.
MOVE THROUGH RECORDS
Create Forms
6
You can move through the records in a form to review and edit information. REC RECORREDCORDO1R3D R E C 1 R O ECORD 1 RD 11 2 RECORD RE R 0 9 D8 RECORRDECORDCO R 7 E C O 6 R R D E C 5 O R R E CORD 3 D 4 RECORRDECORD 2 1 ID
ID Custome 3 r Name ID Geoffrey Custome Address 3 Hill r Nam e Ge Custome offrey Hill 14 Spe 3 r NamAd Custome ncer Ave e dre Gess 3 r Name Addre . offrey Hill 14 Spence Geoffrss r Address 3 ey Hill Ave . 14 Spe City ncer Ave Geoffrey 14 Spe Indianapo Hill State . ncer AveCity lis . 14 Spe State ncer Ave City Zip CoIndianapolis IN City de . Indianapo State IN Zip lis Code Indian State 46206 IN Zip Coapolis de Ind IN Zipian 46206 Coapo de lis IN 46206 46206 46206 ID
ID
ID Custome ID r Name Custome 3 ID r Name Ad Custome dress Geoffr ey Hill r Name Address 3 Custome Geoffrey r Name Address3 14 Spe Hill Geoffr ncer Ave 3 r Name Addre ey Hill . 14 ss Geoffrey Spence r Ave. City r Name Address 3 Hill ID 14 Spe City Custome nce Ge offr r 3 Ave. ey Hill r Name Address 14 Spe State City ncer Ave Custome Indian Geoffrey State apolis 3 . r NamAd Hill 14 Spe Zip e dre ncer Ave City Indianapo Gess State offrey Hill IN Code Address 3 Zip Co City . 14 Spe lis Ind de nce Sta Geoffr ian r Ave. te apolis IN ey Hill Zip Co Cit 14 Spe Indian State de ncer Ave y IN Zip Co apolis 46206 14 Spe . Indianapo ncer Ave City Sta IN de te Zip Code lis 46206 . City Indianapo State IN 46206 Zip Co de lis Ind State IN 46206 Zip Coianapolis de Indianapo IN 46206 Zip Co lis de IN 46206 46206 46206 ID
ID
ID
ID Custome Address
r Name
City State Zip Co
de
Custome
Custome
AD3
HSUP
MOVE THROUGH RECORDS
7
1
Tribute Electronics : ...
This area displays the number of the current record and the total number of records.
12:00 PM
Customers
Tribute Electronics : ...
⁄ To move to another
MOVE TO A SPECIFIC RECORD
record, click one of the following buttons:
⁄ To quickly move to a
First record Previous record Next record
specific record, drag the mouse over the number of the current record. The number is highlighted.
Customers
12:00 PM
¤ Type the number of the record you want to move to and then press the Enter key.
Last record
145
EDIT DATA
You can edit the data displayed on a form to correct a mistake or update data.
San D i
ego co cis ran F n Sa
Access automatically saves the changes you make to the data displayed on a form. When you change data on a form, Access will also change the data in the table you used to create the form.
Chic
ago a nt
la
At
EDIT DATA
East
Tribute Electronics ...
INSERT DATA
⁄ Click the location in the cell where you want to insert data. A flashing insertion point appears in the cell, indicating where the data you type will appear.
146
12:00 PM
Customers
Note: You can press the or key to move the insertion point.
¤ Type the data you want to insert.
Tribute Electronics ...
DELETE DATA
⁄ To delete data, drag the mouse over the data until you highlight the data you want to delete.
Customers
12:00 PM
¤ Press the
Delete key to delete the highlighted data.
Note: To delete a single character, position the insertion point to the right of the character you want to delete and then press the Backspace key.
Create Forms
Tip
Why does the existing data disappear when I type new data?
When OVR appears at the bottom right corner of your screen, the Overtype feature is on. When this feature is on, the data you type will replace the existing data. To turn off the Overtype feature, press the Insert key.
Tip
6
Why can't I edit the data in a cell?
You may be trying to edit data in a field that has the AutoNumber data type. A field that has the AutoNumber data type automatically numbers each record for you to uniquely identify each record. For more information on data types, see page 82.
1 Chicken 2 2 Omelet 3 Vegg ie Pizz 4 Lasagna
OVR
Deep River
Tribute Electronics ...
REPLACE ALL DATA IN A CELL
⁄ To replace all the data in a cell with new data, drag the mouse over the data until you highlight all the data in the cell.
Customers
12:00 PM
Note: In some forms, you can click the name of the field to quickly highlight all the data in a cell.
Tribute Electronics ...
Customers
¤ Type the new data.
UNDO CHANGES
The data you type replaces the data in the cell.
⁄ Click
12:00 PM
to immediately undo your most recent change. Note: If you move to another cell and then click , Access will undo all the changes you made to the entire record.
147
2
ADD A RECORD
R
E
C
O
R
D
You can add a new record to a form to insert additional information into your database. For example, you can add information about a new customer.
R D R E C O
1
Access automatically saves each new record you add to a form. When you add a record to a form, Access also adds the record to the table you used to create the form. ADD A RECORD
1
Tribute Electronics : ...
⁄ Click to add a new record to your form.
Customers
12:00 PM
In this example, a blank form appears.
Tribute Electronics : ...
¤ Click the first empty field in the form. ‹ Type the data that corresponds to the field and then press the Tab key to move to the next field.
148
Customers
12:00 PM
In this example, the ID field automatically adds a number for the new record.
› Repeat step 3 until you finish entering all the data for the record.
DELETE A RECORD
Create Forms
6
R E
You can delete a record displayed in a form to permanently remove information you no longer need. For example, you may want to remove information about a customer who no longer orders your products.
C O R D 2 1
4 O R D R E C 3 R D O C R E 1 D O R R E C
When you delete a record displayed in a form, Access also removes the record from the table you used to create the form. Deleting records saves storage space on your computer and keeps your database from becoming cluttered with unnecessary information.
1
DELETE A RECORD
Tribute Electronics : ...
⁄ Display the record you want to delete. Note: For information on moving through records in a form, see page 145.
Customers
¤ Click record.
12:00 PM
to delete the
Tribute Electronics : ...
The record disappears from the form.
Customers
12:00 PM
‹ Click Yes to permanently delete the record.
A warning dialog box appears.
149
Last Name First Name City
Last Name First Name City
Last Na
me
First N
ame
Addres
s
State
City
State
CHAPTER 7
Design Forms Are you interested in customizing the layout and design of your forms? This chapter shows you how to move or resize items, change the appearance of data, undo changes, add a picture to a form and more. Change the View of a Form..............152 Move or Resize a Control ................154 Delete a Control..............................156 Change the Size of a Form ..............157 Add a Field ....................................158 Add a Label ..................................159 Change Label Text ..........................160 Bold, Italicize or Underline Data ......161 Change the Font of Data ..................162 Change the Size of Data..................163 Change the Color of a Control ........164 Change the Alignment of Data..........166 Undo Changes................................167 Add a Picture..................................168 Apply Conditional Formatting ..........170 Apply an AutoFormat ......................172
CHANGE THE VIEW OF A FORM
You can view a form in five different ways. Each view allows you to perform different tasks.
Design View Form View Datasheet View PivotTable View Tribute Electronics : ...
Order Details
12:00 PM
PivotChart View
CHANGE THE VIEW OF A FORM
1
Tribute Electronics : ...
In this example, the form appears in the Form view.
⁄ Click
in this area to display the form in a different view.
152
Order Details
12:00 PM
¤ Click the view you want to use.
Tribute Electronics : ...
The form appears in the view you selected. In this example, the View button changed from to .
Order Details : Form
12:00 PM
To quickly switch between the Form ( ) and Design ( ) views, click the View button.
Design Forms
7
THE FORM VIEWS Design View
Form View
The Design view allows you to change the layout and design of a form. You can customize a form to make the form easier to use or to enhance the appearance of the form.
The Form view usually displays one record at a time in an organized and attractive format. You can use this view to review, enter and edit information.
23461
Datasheet View
The Datasheet view displays all the records in rows and columns. The field names appear across the top of the window and the information for one record appears in each row. You can review, enter and edit information in this view.
23461 Evans Smith Smith Smith Evans Evans Nelson Nelson Grant Grant Grant Nelson Morris
PivotTable View
PivotChart View
The PivotTable view allows you to summarize and analyze the data in a form. When you first display a form in this view, the PivotTable is empty and you must add the fields you want the PivotTable to display. For information on using the PivotTable view, see page 232.
The PivotChart view allows you to display a graphical summary of the data in a form. When you first display a form in this view, the PivotChart is empty and you must add the fields you want the PivotChart to display. For information on using the PivotChart view, see page 238.
153
MOVE OR RESIZE A CONTROL
You can change the location and size of a control on a form.
Moving a control allows you to change the order of information on a form. Resizing a control allows you to display more or less information in a control.
RESIZE
MOVE Address ID First Name Last Name
Address ID
5
5
Linda
First Name
Linda
Harris
Last Name
Harris
Address
36 Pine St.
Address
36 Pine St.
City
Jacksonville
City
Jacksonville
State
FL
State
FL
Postal Code
32256
Postal Code
32256
A control is an item on a form, such as a label that displays a field name or a text box that displays data from a field. MOVE A CONTROL
Tribute Electronics : ...
⁄ Display the form you want to change in the Design view. To change the view of a form, see page 152. ¤ Click the control you want to move. Handles ( ) appear around the control. 154
Customers : Form
12:00 PM
‹ Position the mouse over the border of the control ( changes to ) and then drag the control to a new location on the form.
Tribute Electronics : ...
In this example, the label and corresponding text box appear in the new location.
› Click
to save your change.
Customers : Form
12:00 PM
To move a label or text box individually, perform steps 1 to 3, except position the mouse over the large handle ( ) at the top left corner of the control in ). step 3 ( changes to
Design Forms
Tip
How can I quickly resize a label to fit its contents?
Tip
7
How can I make small changes to the size of a control?
To make small changes to the size of a control, click the control you want to resize and then press and hold down the Shift key as you press the , , or key.
⁄ Click the label you want to resize to fit its contents.
‹ Click Size. › Click To Fit.
¤ Click Format. RESIZE A CONTROL
Tribute Electronics : ...
Customers : Form
⁄ Display the form you want to change in the Design view. To change the view of a form, see page 152. ¤ Click the control you want to resize. Handles ( ) appear around the control.
12:00 PM
‹ Position the mouse over a handle ( changes to , , or ) and then drag the handle until the control is the size you want.
Tribute Electronics : ...
The control appears in the new size.
Customers : Form
12:00 PM
› Click to save your change.
155
DELETE A CONTROL ORM SSES F E R D D A
You can delete a control you no longer want to appear on a form.
mber Order Nu e Client Nam Address
al
e e
m
A control is an item on a form, such as a label that displays a field name or a text box that displays data from a field.
Na
ntry
Cou
st
us
e
Po
o Sp
City ince od v State/PCro
DELETE A CONTROL
Tribute Electronics : ...
Products : Form
⁄ Display the form you want to change in the Design view. To change the view of a form, see page 152. ¤ To delete a text box and its corresponding label, click the text box. Handles ( ) appear around the text box.
156
12:00 PM
To delete only a label, click the label. Handles ( ) appear around the label.
‹ Press the
Delete
key.
Tribute Electronics : ...
In this example, the text box and its corresponding label disappear.
Products : Form
› Click change.
12:00 PM
to save your
CHANGE THE SIZE OF A FORM
You can change the size of an entire form. Increasing the size of a form can give you more room to add information such as a new field or a picture.
Design Forms
Client Name
Home Phone
Company Name
Work Phone
Address
Fax Number
7
City Client Name State/Province State/P Company Name Postal C Code Address
CHANGE THE SIZE OF A FORM
Tribute Electronics : ...
⁄ Display the form you want to change in the Design view. To change the view of a form, see page 152.
Order Details : Form
12:00 PM
¤ Position the mouse over the right or bottom edge of the form ( changes to or ).
Tribute Electronics : ...
The form changes to the new size.
Order Details : Form
› Click
12:00 PM
to save your
change.
‹ Drag the edge of the form to the size you want.
157
ADD A FIELD
You can add a field to a form when you want the form to display additional information.
Work Phone
Client Name Address City
Home Phone
State/Province
For example, you may want to add a Telephone Number field to a form that displays customer addresses.
Postal Code
Adding a field to a form is useful if you did not include all the fields from a table when you created a form.
NewNFeiew Field ld
ield NewNeFw Field
d Fiel w e N
ADD A FIELD
Fax Number
Fax Number
Tribute Electronics : ...
Customers : Form
12:00 PM
Tribute Electronics : ...
⁄ Display the form you want to change in the Design view. To change the view of a form, see page 152.
‹ Position the mouse over the field you want to add to your form. › Drag the field to
The label and corresponding text box for the field appear on your form.
¤ Click to display a list of fields from the table you used to create the form.
where you want the field to appear on your form.
Note: To move or resize the label or text box, see page 154.
158
Customers : Form
12:00 PM
ˇ Click to save your change. Á To hide the box displaying the list of fields, click .
ADD A LABEL
Design Forms
You can add a label that you want to appear for each record on a form. Labels are useful for displaying important information.
en kehniyckCehnick icC h C y r r P Trry ur C 59
Recipe ID Recipe Name
❧ ❧❧ ❧❧ ❧ ❧❧ ❧❧
Lemon Fish
7
❧❧❧❧❧ ❧❧❧❧❧
45 Minutes
Preparation Time Number of Servings
4
Only include low-fat recipes 250mL 150mL 50mL
ADD A LABEL
A
Tribute Electronics: ...
⁄ Display the form you want to change in the Design view. To change the view of a form, see page 152.
¤ Click
on the Toolbox toolbar to add a label to your form.
Order Details: Form
12:00 PM
Tribute Electronics: ...
If the Toolbox toolbar is not displayed, click to display the toolbar.
› Type the text for the label and then press the Enter key.
‹ Click the location on
Note: If the Error Checking button ( ) appears beside the label, click the button and then click Ignore Error to remove the button from your screen.
your form where you want the top left corner of the label to appear.
Order Details: Form
ˇ Click
12:00 PM
to save your
change. Note: To move or resize the label, see page 154. To delete a label from a form, click the label and then press the Delete key.
159
CHANGE LABEL TEXT
You can change the text displayed in a label to make the label more descriptive.
Product ID
me
Product Na
Category ss
Addre in e Unit Pricllars U.S. Do
Unit Price
You should not change the text in a text box. This text tells Access where to find the information that will appear in the text box. CHANGE LABEL TEXT
Tribute Electronics : ...
⁄ Display the form you want to change in the Design view. To change the view of a form, see page 152. ¤ Click the label you want to change. 160
Order Details : Form
12:00 PM
‹ To select all the text in the label, drag the mouse over the text until you highlight all the text.
Tribute Electronics : ...
› Type the new text for the label and then press the Enter key.
Order Details : Form
ˇ Click change.
12:00 PM
to save your
BOLD, ITALICIZE OR UNDERLINE DATA
Design Forms
7
You can bold, italicize or underline data on a form to emphasize information.
BOLD, ITALICIZE OR UNDERLINE DATA
Outdoor Sporting Go...
Mailing List : Form
⁄ Display the form you
‹ Click one of the
want to change in the Design view. To change the view of a form, see page 152.
following buttons.
¤ Click the control that
Underline
displays the data you want to bold, italicize or underline.
Bold Italic
12:00 PM
Outdoor Sporting Go...
Mailing List : Form
12:00 PM
The data in the control appears in the new style.
› Click
Note: If the control is not large enough to display all the data, you can increase the size of the control. To resize a control, see page 155.
To remove a bold, italic or underline style from data, repeat steps 1 to 4.
to save your
change.
161
CHANGE THE FONT OF DATA
You can change the font of data in a control to enhance the appearance of a form.
Address ID
First Name Last Name
5
son n i b o R
A control is an item on a form, such as a label that displays a field name or a text box that displays data from a field. CHANGE THE FONT OF DATA
Haettenschweiler
Tribute Electronics : ...
Customers : Form
⁄ Display the form you want to change in the Design view. To change the view of a form, see page 152.
‹ Click
¤ Click the control that displays the data you want to change to a different font.
want to use.
162
12:00 PM
in this area to display a list of the available fonts.
› Click the font you
Tribute Electronics : ...
The data changes to the font you selected. Note: If the control is not large enough to display all the data, you can increase the size of the control. To resize a control, see page 155.
Customers : Form
ˇ Click change.
12:00 PM
to save your
CHANGE THE SIZE OF DATA
Design Forms
7
You can increase or decrease the size of data in a control.
Access measures the size of data in points. There are 72 points in an inch. A control is an item on a form, such as a label that displays a field name or a text box that displays data from a field. CHANGE THE SIZE OF DATA
9
16
Tribute Electronics : ...
⁄ Display the form you want to change in the Design view. To change the view of a form, see page 152. ¤ Click the control that displays the data you want to change to a new size.
Order Details : Form
12:00 PM
‹ Click
in this area to display a list of the available sizes.
› Click the size you want to use.
Tribute Electronics : ...
The data changes to the size you selected.
Order Details : Form
ˇ Click change.
12:00 PM
to save your
Note: If the control is not large enough to display all the data, you can increase the size of the control. To resize a control, see page 155.
163
CHANGE THE COLOR OF A CONTROL
You can change the background color and text color of a control to emphasize information on a form.
Last Name
Last Name
First Name
First Name
City
City
Make sure you select background and text colors that work well together. For example, red text on a blue background can be difficult to read.
State State
A control is an item on a form, such as a label that displays a field name or a text box that displays data from a field. CHANGE THE BACKGROUND COLOR
Outdoor Sporting Go...
⁄ Display the form you want to change in the Design view. To change the view of a form, see page 152. ¤ Click the control you want to change to a different background color.
164
Mailing List : Form
12:00 PM
‹ Click
in this area to display the available background colors.
› Click the background color you want to use.
Outdoor Sporting Go...
The control displays the background color you selected.
Mailing List : Form
ˇ Click change.
12:00 PM
to save your
Design Forms
Tip
Can I change the color of several controls at once?
Tip
Yes. To select each control you want to change to a different color, hold down the Shift key as you click each control. Handles ( ) appear around each control you select. To select the background color or text color you want to use, perform steps 3 and 4 below.
7
How can I quickly reapply the last color I used?
The Fill Color ( ) and Font Color ( ) buttons show the last background and text color you used. To reapply the last background or text color you used, click the control you want to change and then click the Fill Color ( ) or Font Color ( ) button.
Last Na
me
First N
ame Addres s City
CHANGE THE TEXT COLOR
Outdoor Sporting Go...
⁄ Display the form you want to change in the Design view. To change the view of a form, see page 152.
Mailing List : Form
12:00 PM
‹ Click in this area to display the available text colors.
Outdoor Sporting Go...
The text in the control displays the color you selected.
Mailing List : Form
ˇ Click
12:00 PM
to save your
change.
› Click the text color you want to use.
¤ Click the control that displays the text you want to change to a different color. 165
CHANGE THE ALIGNMENT OF DATA
You can align data on a form in three different ways.
1
Order ID Date Sold
1/12/2002
Quantity
350
Unit Price When a form is displayed in the Form view, Access automatically left aligns text and right aligns numbers and dates on the form.
Right
Center
$299.99
Product Name
DVD Player
Company Name
Emerald Creek Electronics
Left
CHANGE THE ALIGNMENT OF DATA
Tribute Electronics : ...
⁄ Display the form you want to change in the Design view. To change the view of a form, see page 152. Note: When a form is displayed in the Design view, all data initially appears left aligned.
Order Details : Form
¤ Click the control that displays the data you want to align differently.
‹ Click one of the following buttons. Left align Center Right align
166
12:00 PM
Tribute Electronics : ...
The data in the control appears in the alignment you selected.
Order Details : Form
› Click change.
12:00 PM
to save your
UNDO CHANGES
Design Forms
Access remembers the last changes you made to a form. If you regret these changes, you can cancel them by using the Undo feature.
7
Disco
unt e ric le P a S
Access can only undo changes you made since you last opened the form. UNDO CHANGES
Tribute Electronics : ...
⁄ When working with a form in the Design view, click to undo the last change you made to your form.
Order Details : Form
Note: To change the view of a form, see page 152.
12:00 PM
Tribute Electronics : ...
Access cancels the last change you made to your form in the Design view.
Order Details : Form
12:00 PM
To reverse the results of using the Undo feature, click .
You can repeat step 1 to cancel previous changes you made to your form in the Design view.
167
ADD A PICTURE
ID You can add a picture to a form to make the form more appealing or to help illustrate your data.
Customer Billing Address City
48641 Aquatic World 39 Victoria Road New York
State/Province
NY
Postal Code
10199
You can add a picture such as your company logo, a colorful design or a picture of your products. If you want to display a different picture for each record, such as a picture of each employee, see page 102.
ADD A PICTURE
Tribute Electronics : ...
Order Details : Form
⁄ Display the form you want to add a picture to in the Design view. To change the view of a form, see page 152. ¤ Click on the Toolbox toolbar to add a picture to your form. 168
12:00 PM
If the Toolbox toolbar is not displayed, click to display the toolbar.
Tribute Electronics : ...
‹ Click the location on your form where you want the top left corner of the picture to appear.
Order Details : Form
12:00 PM
The Insert Picture dialog box appears.
Design Forms
Tip
Where can I obtain pictures that I can add to my forms?
Tip
You can use a drawing program to create your own pictures or use a scanner to scan existing pictures into your computer. You can also buy a collection of pictures, called clip art, at stores that sell computer software. Many pages on the Web also offer pictures that you can use.
7
How can I delete a picture I added to a form?
To delete a picture you no longer want to appear on a form, click the picture and then press the Delete key. Access will remove the picture from the form, but will not remove the original picture from your computer. 48641 c World oria Road ork
COL
OR
VIEW
Click Clic k
Delete COMPACT
CLIP ART CD-ROM
Tribute Electronics Logo
273 Jones Road, San Diego, California 92119
Tribute Electronics : ...
This area shows the location of the displayed pictures. You can click this area to change the location.
Order Details : Form
12:00 PM
› Click the name of the picture you want to add to your form.
ˇ Click OK to add the
Tribute Electronics : ...
The picture appears on your form.
Á Click
Order Details : Form
12:00 PM
Note: To move or resize the picture, see page 154.
to save your
change.
picture to your form.
169
APPLY CONDITIONAL FORMATTING
You can have Access apply special formatting to data in a field when the data meets a condition you specify. Applying conditional formatting to data in a field allows you to easily monitor data of interest.
INVENTORY
For example, when the number of units in stock for a product falls below 10, you can have the number appear in red.
Pro duct
In Stock
L ife Jackets
19
Canoe Paddles
135
Boat Cushions
23
In Stock 108
Sleeping Bags Tents
54
Compasses
Emergency Whistles
Bailing Buckets Fishing Rods
Product
120
Portable Stoves
33 12
12
APPLY CONDITIONAL FORMATTING
between
Outdoor Sporting Go...
⁄ Click anywhere in the field that displays the data you want to apply conditional formatting to. ¤ Click Format.
170
Products
‹ Click Conditional Formatting. The Conditional Formatting dialog box appears.
12:00 PM
Outdoor Sporting Go...
12:00 PM
Products
This area displays how the data currently appears in the field.
ˇ Click the operator you
› Click this area to select
type the value that specifies the data you want to apply conditional formatting to.
the operator you want to use to specify the data you want to apply conditional formatting to.
want to use.
Á Click this area and then
Design Forms
Tip
What operators can I use?
= Operator between 100 > and 200 between 100 + not and 200 < equal to 100 equal to 100 1 not greater than 100 2
less than 100 greater than or
3 equal to 100 less than or 4 equal to 100
Outdoor Sporting Go...
‡ If you selected between or not between in step 5, click this area and type the second value.
° To add a background color to data that meets the condition you specified, click in this area.
Products
Tip
Result Formats data between 100 and 200. Formats data not between 100 and 200. Formats data equal to 100. Formats data not equal to 100. Formats data greater than 100. Formats data less than 100. Formats data greater than or equal to 100. Formats data less than or equal to 100.
12:00 PM
· Click the background color you want to use. ‚ To change the color of data that meets the condition you specified, you can repeat steps 8 and 9 in this area.
7
How do I remove conditional formatting from a field?
In the Conditional Formatting dialog box, click Delete. In the Delete Conditional Format dialog box that appears, click Condition 1 ( changes to ) and then press the Enter key.
Outdoor Sporting Go...
12:00 PM
Products
— To bold ( ), italicize ( ) or underline ( ) data that meets the condition you specified, click the appropriate button. This area displays how the data that meets the condition you specified will appear on your form.
± Click OK to confirm your changes. When data in the field meets the condition you specified, the data will display the format you specified.
171
APPLY AN AUTOFORMAT
You can apply an autoformat to quickly change the overall appearance of a form.
You may want to use the same autoformat for every form in your database to give your database a consistent appearance. APPLY AN AUTOFORMAT
Tribute Electronics : ...
⁄ Display the form you want to change in the Design view. To change the view of a form, see page 152.
172
Order Details: Form
12:00 PM
¤ Click to select the form ( changes to ).
Tribute Electronics : ...
‹ Click to select an autoformat for the form.
Order Details: Form
12:00 PM
The AutoFormat dialog box appears.
Design Forms
7
Why didn't my entire form change to the new autoformat?
Tip
If your form contains a subform, the appearance of the subform will not change when you apply an autoformat to the form. A subform displays information from a related table in your database. To apply an autoformat to a subform, open the subform as you would open any form and then perform the steps shown below. To open a form, see page 144.
Subform
Note: If your subform appears in the Datasheet layout, applying an autoformat to the subform will have no effect on the appearance of the subform.
Stone
Tribute Electronics : ...
› Click the autoformat you want to use.
Order Details: Form
12:00 PM
ˇ Click OK to confirm your change.
Tribute Electronics : ...
The form displays the new autoformat.
Order Details: Form
Á Click
12:00 PM
to save your
change.
This area displays a sample of the autoformat you selected.
173
Book I s
Year
shed Publi
Castle
315
360
Still Waters Run Deep
4
rbit
s in O
ceship
1
400
1990 1994 2001
ality
unted
Page
mak St. CA e Si Juli 06 Bluengeles, d. 9 os A oll arr lar R L 0009 ey C ctacu CA 9 v r e a ,
5 The
375
1996
Tou
rist
H
20
01
54
5
Sp ity 146 ster C Fo 649 mas 90 Jeff Tho or y Lane em 14 M ank, CA Burb 4 9150
5
8
CHAPTER 8
Find Data Do you often need to find specific data in your database? In this chapter, you will learn how to sort, find, replace and filter data. Sort Records ..................................176 Find Data ......................................178 Replace Data ..................................180 Filter by Selection ............................182 Filter by Input..................................184
ok ID 1
5
8
Title Spaceships in Orbit
Year Published Pages 2001
360
2 Escape from Reality
1990
400
3 Hugh’s Haunted Castle
1994
315
4 Still Waters Run Deep
1996
375
2001
545
6 The Cowboy Invasion
1993
250
7 My Clandestine Ways
1991
325
2001
425
The UnfTourist
The Magical Lilac Tree
Filter by Exclusion............................185 Filter by Form..................................186
SORT RECORDS s
Page
ed
sh Publi Year
You can change the order of records in a table, form or in the results of a query. Sorting records can help you find, organize and analyze data.
Book
ID
400
1990
Title lity
Rea e from
ap 2 Esc
e
d Castl
aunte gh's H
3 Hu
hips in
ces 1 Spa
315
1994
360
1996
Orbit
545 1997
375
ourist
iar T nfamil
1996
eU 5 Th
rs ll Wate 4 Sti
eep
Run D
SORT RECORDS
$400.00
Outdoor Sporting Go...
Payments : Table
SORT BY ONE FIELD
¤ Click one of the
⁄ Click anywhere in
following buttons.
the field you want to use to sort the records.
176
Sort A to Z, 1 to 9 Sort Z to A, 9 to 1
12:00 PM
Outdoor Sporting Go...
The records appear in the new order. In this example, the records are sorted by payment amount.
Payments : Table
12:00 PM
Find Data
Tip
8
How do I remove a sort from my records?
After sorting records, you can return your records to the original sort order at any time.
⁄ Click Records. ¤ Click Remove Filter/Sort.
Note: If you rearranged fields to sort your records by two fields, removing a sort will not return the fields to their original locations.
Payment Method Payment Amount $400.00 Cash $400.00 Check $350.00 Cash $320.00 Cash $200.00 Credit Card $150.00 Check $145.00 Check $125.00 Check $120.00 Check $120.00 Check $85.00 Credit Card $80.00 Cash $74.00 Check $50.00 Check
Outdoor Sporting Go...
Payments : Table
Cash
12:00 PM
Outdoor Sporting Go...
SORT BY TWO FIELDS
¤ Position the mouse
‹ Click one of the
⁄ Place the fields you want
over the name of the first field you want to use to sort the records ( changes to ). Then drag the mouse until you highlight the second field.
following buttons.
to use to sort the records side by side and in the order you want to perform the sort. Access will sort the leftmost field first. To rearrange fields, see page 45.
Sort A to Z, 1 to 9 Sort Z to A, 9 to 1
Payments : Table
12:00 PM
The records appear in the new order. In this example, the records are sorted by payment method. All records with the same payment method are also sorted by payment amount.
177
FIND DATA
You can search for data of interest in a table, form or in the results of a query.
FIND DATA
Jason Carl Simon Paul Sue Linda Frank David Nancy Stacy Ann Amy Sara
Cook Davis Evans Fraser Grant Harris Hill Jones King Lee Lewis Martin Miller
Outdoor Sporting Go...
⁄ Click anywhere in the field that contains the data you want to find.
178
Whole Field
Ann Amy Sara
Mailing List : Table
¤ Click
12:00 PM
to find the
data. The Find and Replace dialog box appears.
Lewis Martin Miller
Outdoor Sporting Go...
‹ Type the data you want to find. › To specify how you want to search for the data, click this area.
Mailing List : Table
ˇ Click the way you want to search for the data. Note: For information on the ways you can search for data, see the top of page 179.
12:00 PM
Find Data
Tip
8
How can I search for data in a field?
Smith Smithson Macsmith
Smith Smithson Macsmith
Smith Smithson Macsmith Any Part of Field
Whole Field
Start of Field
Finds data anywhere in a field. For example, a search for smith finds Smith, Smithson and Macsmith.
Finds data that exactly matches the data you specify. For example, a search for smith finds Smith, but not Smithson or Macsmith.
Finds data only at the beginning of a field. For example, a search for smith finds Smith and Smithson, but not Macsmith.
Ann Amy Sara
Lewis Martin Miller
Outdoor Sporting Go...
Á Click Find Next to start the search. Access highlights the first instance of matching data in the field.
Amy Sara
Seattle
Mailing List : Table
12:00 PM
If the Find and Replace dialog box covers the highlighted data, position the mouse over the title bar and then drag the dialog box to a new location.
‡ Click Find Next to find the next instance of matching data in the field.
Martin Miller
Outdoor Sporting Go...
Mailing List : Table
12:00 PM
° Repeat step 7 until a
‚ To close the Find
dialog box appears, telling you the search is complete.
and Replace dialog box, click Cancel.
· Click OK to close the dialog box.
179
REPLACE DATA Address ID
You can find and replace data in a table, form or in the results of a query. The Replace feature is useful when you want to make the same change to many records.
First Name
Last Name
Address
City
State/Province Postal Code
1 Jack
Adams
258 Linton Ave. New York
NY
10010
2 Lisa
Bell
50 Tree Lane
MA
02117
3 Ann
Lewis
68 Cracker Ave. San Francisco CA
94110
4 Sara
Miller
47 Crosby Ave. Bosten
MA
02118
5 Daniel
Price
26 Arnold Cres. Jacksonville
FL
32256
6 Janet
Young
401 Idon Dr.
Nashville
TN
37243
7 Josh
Nelson
10 Heldon St.
Atlanta
GA
30375
8 Julie
Brown
TN
37245
Bosten
36 Buzzard St. Nashville SEARCH
Bosten
REPLACE DATA
Tribute Electronics : ...
⁄ Click anywhere in the field that contains the data you want to replace with new data. ¤ Click
180
.
Orders : Table
12:00 PM
Tribute Electronics : ...
The Find and Replace dialog box appears.
ˇ Click this area and type the new data.
‹ Click the Replace tab. › Type the data you
This area indicates how Access will search for the data. You can click this area to change how Access will search for the data.
want to replace with new data.
Orders : Table
12:00 PM
Note: For information on the ways you can search for data, see the top of page 179.
Á Click Find Next to start the search.
Find Data
Tip
How do I move the Find and Replace dialog box?
Tip
To move the Find and Replace dialog box so you can clearly view the data in your table, form or query, position the mouse over the title bar of the dialog box and then drag the dialog box to a new location.
8
How can the Replace feature help me quickly enter data?
You can type a short form of a word or phrase, such as MA, when entering data in a field. You can then use the Replace feature to replace the short form with the full word or phrase, such as Massachusetts.
M
A DX-7730
CD Player CD Changer
Tribute Electronics : ...
Orders : Table
12:00 PM
Access highlights the first instance of matching data in the field.
Find Next - Skip the data and find the next instance of matching data in the field.
‡ Click one of the
Replace - Replace the data.
following options.
Replace All - Replace the data and all other instances of matching data in the field.
Note: If you select Replace All, a dialog box will appear. Click Yes to continue.
Tribute Electronics : ...
In this example, Access replaces the data and searches for the next instance of matching data in the field.
12:00 PM
Orders : Table
· Click OK to close the dialog box. ‚ To close the Find and Replace dialog box, click Cancel.
° Repeat step 7 until a dialog box appears, telling you the search is complete.
181
FILTER BY SELECTION imak Julie S e St. u 906 Bl eles, CA g A s Lo n 90009
You can filter records in a table, form or in the results of a query to display only the records that contain data of interest. Filtering records can help you review and analyze information in your database.
oll y Car r . Har ve ctacular Rd e p A 146 S City, C Foster 90649 Jeff Thomas 14 Memory Lane Burbank, CA 91504
For example, you can filter records to display only the records for customers who live in California. FILTER BY SELECTION
Jack Erin Lisa Julie Alan Matt Jason Carl Simon Paul Sue Linda Frank David
Adams Baker Bell Brown Carter Cole Cook Davis Evans Fraser Grant Harris Hill Jones
Tribute Electronics : ...
⁄ Click the data you want to use to filter the records. Access will display only the records that contain exactly the same data.
182
Jack Julie Alan Carl Sue Linda
Employees : Table
12:00 PM
Note: You can select data to change the way Access filters records. For more information, see the top of page 183.
Adams Brown Carter Davis Grant Harris
Tribute Electronics : ...
¤ Click
to filter the
records. Access displays only the records that contain the same data. All other records are temporarily hidden.
Sales
Employees : Table
12:00 PM
In this example, Access displays only the employees in the Sales department.
Find Data
Tip
8
How can I change the way Access filters records?
You can select data to change the way Access filters records. To select data, see page 55.
SMITH
Jack Julie Alan Carl Sue Linda
SMITH
SMITHSON SMILEY
SMITH
RONSONVILLE
SONY SMITHSON
Exact Match
First Characters
Any Characters
If you do not select any data, Access will only find data that matches exactly. For example, Smith finds only Smith.
If you select part of a word, starting with the first character, Access will find data that starts with the same characters. For example, Smith finds Smithson and Smiley.
If you select part of a word, starting after the first character, Access will find any data that contains the selected characters. For example, Ronsonville finds Sony and Smithson.
Adams Brown Carter Davis Grant Harris
Tribute Electronics : ...
The word Filtered appears in this area to indicate that you are viewing filtered records.
Jack Julie Alan Carl Sue Linda
Sales
Employees : Table
To further filter the records, you can repeat steps 1 and 2.
12:00 PM
Adams Brown Carter Davis Grant Harris
Tribute Electronics : ...
Sales
Employees : Table
12:00 PM
‹ When you finish reviewing the filtered records, click to once again display all the records.
183
FILTER BY INPUT
Last Name First Name
You can filter records in a table, form or in the results of a query by entering criteria. Criteria are conditions that identify which records you want to display.
Adams
Jack
Amount $620.70
Jones
Martin
$582.26
David
n Micheal Brow
Julie $120.00
$369.25
$789.20
Amy
Turner Morris
$148.00
Ryan
Smith
Diane
Kevin
$238.00
$825.99
For example, you can enter criteria to display only the records for customers who made purchases of more than $500. FILTER BY INPUT
$525.00
Tribute Electronics : ...
⁄ Right-click anywhere in the field you want to use to filter the records. A menu appears.
184
Order Details : Table
12:00 PM
¤ Click the area beside Filter For:.
‹ Type the criteria you want to use to filter the records. Then press the Enter key. Note: For examples of criteria you can use, see page 187.
Tribute Electronics : ...
Access displays only the records that meet the criteria you specified. All other records are temporarily hidden. In this example, Access displays orders over $300.
Order Details : Table
12:00 PM
The word Filtered appears in this area to indicate that you are viewing filtered records.
› When you finish reviewing the filtered records, click to once again display all the records.
FILTER BY EXCLUSION
You can filter records in a table, form or in the results of a query to hide records that do not contain data of interest.
Book ID 1
5
8
Find Data
Title
8
Year Published Pages 2001
360
2 Escape from Reality
1990
400
3 Hugh’s Haunted Castle
1994
315
4 Still Waters Run Deep
1996
375
2001
545
6 The Cowboy Invasion
1993
250
7 My Clandestine Ways
1991
325
2001
425
Spaceships in Orbit
The UnfTourist
The Magical Lilac Tree
For example, you can filter records to hide the records for all books published in 2001.
FILTER BY EXCLUSION
Jack Erin Lisa Julie Alan Matt Jason Carl Simon Paul Sue Linda Frank David
Tribute Electronics : ...
⁄ Right-click the data you want to use to filter the records. Access will hide all the records that contain exactly the same data. A menu appears.
Sara Josh Mark Janet Erin Lisa Matt Jason Simon Paul Frank David Bob Ryan
Adams Baker Bell Brown Carter Cole Cook Davis Evans Fraser Grant Harris Hill Jones
Employees : Table
12:00 PM
¤ Click Filter Excluding Selection.
Miller Nelson Taylor Young Baker Bell Cole Cook Evans Fraser Hill Jones White Smith
Tribute Electronics : ...
Production
Employees : Table
12:00 PM
Access temporarily hides the records that contain the data you specified.
To further filter the records, you can repeat steps 1 and 2.
In this example, Access hides the employees in the Sales department.
‹ When you finish
The word Filtered appears in this area to indicate that you are viewing filtered records.
reviewing the filtered records, click to once again display all the records.
185
FILTER BY FORM
You can use the Filter by Form feature to find and display records of interest in a table, form or in the results of a query.
Last Name First Name Adams
Amount
Jack
$148.00
Bell
Lisa
$369.25
Paul
$238.00 FEDER
VE NOTE 11000 AL RESER 11111
ONE
1111111000
A
VE NOTE 11000 AL RESER 11111 FEDER
ONE
1111111000 FEDER
ONE
A GEORGE
THE UNITE
S OF AMER
WASHINGTON
D STATE
Grant
FEDER
ICA
NOTE RESERVE 1111111000
ONE
A GEORGE
THE UNITE
S OF AMER
WASHINGTON
D STATE
ONE Sue
A
FEDERAL 1111111000
ONE
S OF AMER
WASHINGTON
D STATE
FEDERAL 1111111000
THE UNITE
7777777
D
FEDER
1
S OF AMER
WASHINGTON
D STATE
1
ONE
ONE
A
7777777
1
A
S OF AMER
WASHINGTON
D STATE
ONE
S OF AMER
ICA
ONE
ONE
FEDER
A WASHINGTO
N
ED STATE
ICA
ONE
A 7777777
1
7777777
GEORGE
THE UNIT
1
7777777
OF AMER
VE NOTE 11000 AL RESER 11111 FEDER
1111111000
ONE
1111111000
7777777
ONE
N WASHINGTO
STATES
GEORGE
ED THE UNIT
1
1
7777777
1
VE NOTE 11000 AL RESER 11111
7777777
ICA N WASHINGTO GEORGE S OF AMER ED STATE THE UNIT VE NOTE 11000 AL RESER 11111 FEDER
1
N
A
7777777
1
WASHINGTO
1111111000
ONE
A
ICA OF AMER STATES
GEORGE
ED THE UNIT
1
1
7777777
1
7777777
7777777
S OF AMER
1
7777777
GEORGE
1
ICA S OF AMER
N WASHINGTO
ED STATE THE UNIT
ICA
1
7777777
GEORGE
THE UNITE
N WASHINGTO
VE NOTE 11000 AL RESER 11111
A
ICA N WASHINGTO GEORGE S OF AMER ED STATE THE UNIT VE NOTE 11000 AL RESER 11111 FEDER
ONE
A
ONAE
A
FEDER
1111111000
WASHINGTON
D STATE
GEORGE
ED STATE THE UNIT
7777777
ICA
1
7777777
7777777
1111111000
1 THE UNITE 1 7777777 VE NOTE 1000 AL RESER 111111 ICA FEDER S OF AMER NOTE RESERVE 1111111000 1111111000 FEDERAL NOTE 1 7777777 10001000 RESERVE 111111 111111 FEDERAL ICA WASHINGTON 7777777 S OF AMER 1 GEORGE 7777777 D STATE 1111111000 1 THE UNITE ICA WASHINGTON S OF AMER 1GEORGE 77777777777777 VE NOTE 1000 D STATE AL RESER 111111 ICAUNITE 1OF AMER THE FEDER WASHINGTON 7777777 GEORGE STATES 1000 D 111111 1 THE UNITE NOTE 7777777 RESERVE 1111111000 ICA FEDERAL WASHINGTON GEORGE 7777777 S OF AMER D STATE 1111111000 1 THE UNITE GEORGE
THE UNITE
1 ICA
A
1
ICA S OF AMER
N
A 1
7777777
GEORGE
S OF AMER
VE NOTE 11000 AL RESER 11111 FEDER 1111111000
ONE
7777777
ED STATE
VE NOTE 11000 AL RESER 11111 FEDER 1111111000
1
7777777
WASHINGTO
GEORGE
THE UNIT
N WASHINGTO
$422.00 ONE
ONE
GEORGE
VE NOTE 1000 AL RESER 111111
A
ONE
1
ICA S OF AMER
N
ED STATE THE UNIT
ICA
1111111000
NOTE RESERVE 1111111000
A 1
1
1 ICA
WASHINGTON
1
1
VE NOTE 11000 AL RESER 11111
7777777
OF AMER STATES
GEORGE
WASHINGTO
FEDER
A
7777777
7777777
7777777
GEORGE
THE UNITE
GEORGE
ED STATE THE UNIT
1111111000
ONE
ONE 7777777
7777777
7777777
7777777
ICA
VE NOTE 1000 AL RESER 111111
A
NOTE RESERVE 1111111000
7777777
S OF AMER
WASHINGTON
D STATE
FEDER
1111111000
A 1
GEORGE
THE UNITE
ICA
1
1
7777777
7777777
1
1
7777777
7777777
1
A
$789.20
Alan
1
7777777
1111111000
ONE
A
VE NOTE 1000 AL RESER 111111
1111111000
FEDERAL 1111111000
Carter
ICA N WASHINGTO GEORGE S OF AMER ED STATE THE UNIT VE NOTE 11000 AL RESER 11111 FEDER
7777777
1
1
7777777
ICA N WASHINGTO GEORGE S OF AMER ED STATE THE UNIT VE NOTE 11000 AL RESER 11111 FEDER 1111111000
7777777
1
1
7777777
7777777
1
A
VE NOTE 1000 AL RESER 111111
1111111000
When you filter by form, you need to specify the criteria that records must meet to appear in the results. For example, you can specify criteria to display only the records for customers who purchased less than $500 of your products.
$582.26
d Davi $120.00
s Micheal Jone Fraser
$620.70
Jason
Cook
ICA
FILTER BY FORM USING ONE CRITERIA
1 Jack
Erin Lisa Julie Alan Matt Jason Carl Simon Paul Sue Linda Frank David
Adams Baker Bell Brown Carter Cole Cook Davis Evans Fraser Grant Harris Hill Jones
Tribute Electronics : ...
⁄ Click to filter your records by form.
186
Employees : Table
The Filter by Form window appears.
12:00 PM
Tribute Electronics:...
This area displays the field names from your table, form or query results.
Employees: Filter by...
12:00 PM
¤ To clear any information used for your last filter, click .
Find Data
What criteria can I use to filter records?
Tip
Tip
Here are some examples of criteria you can use to filter records. For more examples, see page 214.
Criteria
Description
<100 >100
Less than 100
=Texas
Matches Texas
Between 100 and 200
Between 100 and 200
Like Mar*
Starts with “Mar”
Like *mar*
Contains “mar”
Is there another way to enter the criteria I want to use to filter records?
Yes. To enter criteria, you can perform steps 1 to 3 below and then click the arrow ( ) that appears in the area. A list of all the values in the field appears. Click the value you want to use to filter the records.
Greater than 100
2 Erin
1
Julie Alan Matt Jason Sue Ryan Diane
Tribute Electronics:...
8
12:00 PM
Employees: Filter by...
Baker Brown Carter Cole Cook Grant Smith Morris
Tribute Electronics:...
Employees: Table
12:00 PM
‹ Click the blank area for the field you want to use to filter the records.
› Type the criteria to specify which records you want to find.
Access displays only the records that meet the criteria you specified.
The word Filtered appears in this area to indicate that you are viewing filtered records.
Note: If a list appears, press the Esc key to hide the list.
Note: For examples of criteria you can use, see the top of this page.
In this example, Access displays employees who earn more than $60,000.
Á When you finish reviewing
ˇ Click
to filter the
the filtered records, click once again display all the records.
to
records.
187
$2 0
FILTER BY FORM 0
$5
6
M ar St k ac MA y
H
NY
O
n
a Al
OH
When using the Filter by Form feature, you can use multiple criteria to filter your records. Access will find and display records that meet the criteria you specify.
$2
6
$7
A Ry t C ith Jane Stmi CA Cin Carl 4 1 avis 4 D
1
M
Criteria are conditions that identify which records you want to appear in the results. For example, you can specify criteria to display customers living in California who purchased more than $500 of your products. For examples of criteria, see page 214.
an
n
Ad
am
CA
an
CA
$6
00
0
25
$5
$75
$800
FILTER BY FORM USING MULTIPLE CRITERIA
4 Julie
2
Alan Sue
Tribute Electronics:...
"AND" ⁄ To enter the first criteria you want to use to filter the records, perform steps 1 to 4 starting on page 186. USING
Employees: Filter By...
¤ To enter the second criteria, click the blank area for the other field you want to use to filter the records. Then type the second criteria. ‹ Click records.
188
12:00 PM
to filter the
Brown Carter Grant
Tribute Electronics:...
Access displays the records that meet both of the criteria you specified. In this example, Access displays employees in the Sales department who earn more than $60,000.
Employees : Table
12:00 PM
The word Filtered appears in this area to indicate that you are viewing filtered records.
› When you finish reviewing the filtered records, click to once again display all the records.
Find Data
Tip
8
How can I use multiple criteria to filter records? Filter records using "And" Texas Last Name
ID
Last Name
ID
State
Units
1
Cooper
TX
258
2
Bibby
CA
329
3
Mullin
NY
176
4
Simak
TX
346
5
Jones
TX
168
6
Webb
NV
182
>200 State
Units
1
Cooper
TX
258
4
Simak
TX
346
Filter records using "Or" Texas
California ID ID
Last Name
State
Units
1
Cooper
TX
258
2
Bibby
CA
329
4
Simak
TX
346
5
Jones
TX
168
1 Jack
4
Julie Alan Carl Paul Sue Linda Helen
Tribute Electronics:...
Employees: Filter by...
12:00 PM
"OR" ⁄ To enter the first criteria you want to use to filter the records, perform steps 1 to 4 starting on page 186.
‹ To enter the second criteria, click the blank area for the field you want to use to filter the records. Then type the second criteria.
¤ Click the Or tab.
› Click
USING
records.
Displays records that meet all of the criteria you specify. For example, Texas and >200 displays only customers living in Texas who purchased more than 200 units.
to filter the
Displays records that meet at least one of the criteria you specify. For example, California or Texas displays customers who live in California or Texas.
Adams Brown Carter Davis Fraser Grant Harris Reed
Tribute Electronics:...
Employees : Table
12:00 PM
Access displays the records that meet at least one of the criteria you specified.
The word Filtered appears in this area to indicate that you are viewing filtered records.
In this example, Access displays employees in the Sales or Accounting department.
ˇ When you finish reviewing the filtered records, click to once again display all the records.
189
?
What were the top five selling products this week? Product
Product ID
Quantity
1
Water-skis
120
5
Bike
245
13
Tennis racquet
250
18
Basketball
264
23
Running shoes
364
Query
.
x
3
2
1
_
6
5
4
+
9
8
7
C
RM
M-
M+
0
=
/
CHAPTER 9
Create Queries Would you like to create queries to find information of interest in your database? This chapter shows you how. Create a Query in the Design View ..192 Create a Query Using the Simple Query Wizard..............................196 Change the View of a Query............202 Open a Query................................204 Rearrange Fields ............................205 Add Fields ......................................206 Delete a Field ................................208 Hide a Field ..................................209 Sort Query Results ..........................210 Using Criteria to Find Records ..........211 Using Multiple Criteria to Find Records........................................212
? What is the ? Who is the lowest Examples of Criteria ........................214 top ? Which pr Display Highest or Lowest Values ......216 oduct has ? WhichSupesalersstore ordered? Perform Calculations ........................218 reps sold the most products Using Parameters ............................220 this month?
Queries
Summarize Data ............................222 Find Unmatched Records..................226
CREATE A QUERY IN THE DESIGN VIEW
You can create a query to find information of interest in your database.
Which wines were 65? made before 19
Creating a query allows you to find information that meets certain criteria in your database. Criteria are conditions that identify which records you want to find. CREATE A QUERY IN THE DESIGN VIEW
Create query in Design view
Customers
Tribute Electronics : ...
⁄ Click Queries in the Database window.
192
12:00 PM
¤ Double-click Create query in Design view.
Tribute Electronics : ...
Query1 : Select Query
12:00 PM
The Select Query window and the Show Table dialog box appear.
‹ Click a table that
This area lists all the tables in your database.
› Click Add to add the
contains information you want to use in your query. table to your query.
Create Queries
Tip
Why does a line appear between the tables in the Select Query window?
Tip
If the tables you select to use in a query are related, Access displays a line joining the related fields in the tables. When creating a query that uses information from more than one table, the tables should be related so that Access can bring together the information in the tables. For information on relationships, see page 128.
Customers
Orders
* CustomerID CompanyNam BillingAddress City
* CustomerID OrderID ProductName Quantity
9
How do I add another table to my query?
To add another table to your query, click to redisplay the Show Table dialog box. Then perform steps 3 and 4 on page 192 to add another table to your query.
Order Details
Tribute Electronics : ...
Query 1 : Selet Query
12:00 PM
Order Details
Tribute Electronics : ...
A box appears in the Select Query window, displaying the fields for the table you selected.
ˇ To add another table to your query, repeat steps 3 and 4 for each table.
Query1 : Select Query
12:00 PM
Á Click Close to hide the Show Table dialog box.
Tribute Electronics : ...
Each box in this area displays the fields for one table.
Query1 : Select Query
12:00 PM
If you accidentally added a table to the query, click the box displaying the fields for the table and then press the Delete key. Access will remove the table from the query, but will not remove the table from the database.
193
CREATE A QUERY IN THE DESIGN VIEW Select Fields Customers Query: Select Query
You can select which fields from your tables you want to include in your query.
Last Name
First Name
Address
Adams Baker Bell Brown Carter Cole Cook Davis Evans Fraser
Jack Erin Lisa Julie Alan Matt Jason Carl Simon Paul
220 Whittle St. Greenfield 19 Milverton Blvd. Hartford 14 Spencer Ave. Indianapolis 125 Crane St. San Diego 772 Main St. Baltimore 14 Pine St. Freeport 192 College St. Little Rock 85 Elm St. Charlotte 24 Cortez Blvd. Tampa 55 Sunset St. Syracuse
City
State
Phone #
WI CT IN CA MD ME AR NC FL NY
414-555-6325 860-555-6582 317-555-0024 858-555-9713 410-555-3164 207-555-1478 501-555-1230 704-555-3579 813-555-2864 315-555-1675
For example, you may want to include only the name and phone number of each customer. CREATE A QUERY IN THE DESIGN VIEW (CONTINUED)
Quantity Ordered
CompanyName
Tribute Electronics : ...
‡ Double-click a field you want to include in your query.
Query1 : Select Query
12:00 PM
This area displays the field you selected and the table that contains the field.
Tribute Electronics : ...
° To include other fields in your query, repeat step 7 for each field you want to include. Note: To quickly select all the fields in a table, see page 206.
194
Query1 : Select Query
12:00 PM
RUN A QUERY
⁄ Click the query.
to run
Create Queries
Tip
Does a query store data?
9
Can I change information displayed in the results of my query?
Tip
No. When you save a query, Access saves only the design of the query. Each time you run a query, Access gathers the most current data from your database to determine the results of the query. For example, you can run the same query each month to display the top sales representatives for the month.
Yes. You can edit data displayed in the results of a query as you would edit data in a table. If you change the data displayed in the query results, the data will also change in the table used to create the query. To edit data in a table, see page 56.
What is the lowest Who is the top Which product has WhichSupsaleersstorrepesord soldered? the most products this month?
1 Chi k
S
2 Omelet 3 Veggie Pizz a 4 Lasagna 5 Pancakes 6 Pork Chops 7 Garden Sal ad 8
Fruit Salad
Dinner Breakfast Lunch Dinner Breakfast Dinner Lunch Breakfast
No Yes Yes No
Yes No Yes Yes
CC&M Radio Store
Products Sold
Tribute Electronics : ...
The results of the query appear. This area displays the names of the fields you included in the query.
Query1 : Select Query
12:00 PM
The records that meet the conditions you specified appear in this area. In this example, all the records from the table(s) are displayed. To return to the Design view, click .
Tribute Electronics : ...
Query1 : Select Query
12:00 PM
SAVE A QUERY
¤ Type a name for your
⁄ Click
query and then press the Enter key.
to save your query so you can run the query again later. The Save As dialog box appears.
‹ When you finish working with your query, click to close the query.
195
CREATE A QUERY USING THE SIMPLE QUERY WIZARD
You can use the Simple Query Wizard to create a query. A query allows you to find and analyze information of interest in your database.
Query
The Simple Query Wizard will ask you a series of questions and then set up a query based on your answers. CREATE A QUERY USING THE SIMPLE QUERY WIZARD
Create query by using wizard Table: Order Details
Tribute Electronics : ...
⁄ Click Queries in the Database window.
12:00 PM
¤ Double-click Create query by using wizard.
Tribute Electronics : ...
The Simple Query Wizard appears.
‹ Click
in this area to select the table that contains the fields you want to include in your query.
196
12:00 PM
› Click the table that contains the fields.
Create Queries
Which tables in my database can I use to create a query?
Tip
You can use any table in your database to create a query. When creating a query that uses information from more than one table, relationships must exist between the tables so that Access can bring together the information in the tables. For information on relationships, see page 128.
Date
Social Security ID
111-11-1111
10-10-99
Score 97
Concerns
9
Comments Jim has remained
No
9-5
222-22-2222
4
Social Security ID
333-33-3333
7
111-11-1111
444-44-4444
8
222-22-2222
600-60-6000
4
333-33-3333
777-77-7777
3
444-44-4444
888-88-8888
11
600-60-6000
999-99-9999
5
777-77-7777
000-00-0000
6
888-88-8888
000-11-2222
6
999-99-9999
Salary
Position
$42,000
Sales
Hours
Years
5
8-4
12-5
Social Security ID First Name
Accounting
111-11-1111
9-5 8-6
Last Name
222-22-2222
Adams $30,000 Baker Erin 12-5
333-33-3333
Lisa
Bell
Julie
Brown
Jack
2
Address
City
State/Province Postal Code
258 Linton Ave. New York
NY
10010
50 Tree Lane
MA
02117
68 Cracker Ave. San Francisco CA
94110
47 Crosby Ave. Las Vegas
NV
89116
26 Arnold Cres. Jacksonville
FL
32256
Boston
Marketing 444-44-4444 600-60-6000
Hr
1 Alan
Carter
999-99-9999
$38,000 Cole Matt 9-5 Cook Jason 8-6 $55,000 Davis Carl
000-00-0000
Simon
Evans
15 Bizzo Pl.
New York
NY
10020
000-11-2222
Paul
Fraser
890 Apple St.
San Diego
CA
92121
777-77-7777
000-00-0000 888-88-8888 000-11-2222
9-5
Consulting
401 Idon Dr.
Nashville
TN
37243
10 Heldon St.
Atlanta
GA
30375
36 Buzzard St. Boston
MA
02118
8
Quantity Ordered Discount
Product Name
Tribute Electronics : ...
This area displays the fields from the table you selected.
ˇ Double-click each field you want to include in your query.
12:00 PM
Note: To add all the fields from the table at once, click .
Tribute Electronics : ...
Each field you select appears in this area. To remove a field you accidentally selected, double-click the field in this area. Note: To remove all the fields at once, click .
12:00 PM
Á To include fields from other tables in your database, repeat steps 3 to 5 for each table. ‡ Click Next to continue.
197
CREATE A QUERY USING THE SIMPLE QUERY WIZARD
If your query contains information that Access can summarize, you can choose to show all the records or just a summary of the records in the results of your query.
CREATE A QUERY USING THE SIMPLE QUERY WIZARD (CONTINUED)
12:00 PM
Tribute Electronics : ...
This screen appears if your query contains information that Access can summarize.
° Click the way you want
Note: If this screen does not appear, skip to step 16.
· If you selected Summary
198
to display the information in the results of your query ( changes to ). in step 8, click Summary Options. Note: If you selected Detail in step 8, skip to step 15.
12:00 PM
Tribute Electronics : ...
The Summary Options dialog box appears. This area displays the fields you can summarize.
‚ Click the box (
) for each calculation you want to perform ( changes to ). Note: For information on the calculations you can perform, see the top of page 199.
Create Queries
Tip
9
What calculations can Access perform to summarize data in my query?
Sum
Avg
Min
Max
Count records
Adds the values.
Calculates the average value.
Finds the smallest value.
Finds the largest value.
Counts the number of records.
Tribute Electronics : ...
— To count the number of records used in each group to perform the calculations, click this option ( changes to ).
12:00 PM
± Click OK to confirm your selections.
Tribute Electronics : ...
¡ Click Next to continue.
12:00 PM
You can click Back at any time to return to a previous step and change your selections.
199
CREATE A QUERY USING THE SIMPLE QUERY WIZARD By
If a field in your query contains dates, you can specify the way you want to group the dates in your query.
Day Monda y, Janu Qty O ar y 05 rdered , 2004 Tuesda y, Janu ar y 06 10 , 2004 Wedne By Mo sday, J n th anuar y Qty O Thursd 07, 20 Janu rdered ay, Jan ar y 20 02 04 uar y 0 8, 200 50 4 Februar y 2004 By Qu arter March Qty O 2004 rdere Q1 200 d 4 April 2 004 B y Yea Q2 200 r 4 Qty O rdere 2 0 01 d Q3 20 04 350 2002 Q4 20 04 400 2003
2004
You can group dates by day, month, quarter or year.
250 500
CREATE A QUERY USING THE SIMPLE QUERY WIZARD (CONTINUED)
12:00 PM
Tribute Electronics : ...
This screen appears if a field in your query contains dates and you chose to summarize data in your query in step 8.
™ Click the way you
Note: If this screen does not appear, skip to step 16.
continue.
200
want to group the dates in your query ( changes to ).
£ Click Next to
12:00 PM
Tribute Electronics : ...
¢ Type a name for your query. ∞ Click this option to open and review the results of your query ( changes to ).
§ Click Finish to create your query.
Create Queries
Tip
Why didn't my query summarize data the way I expected?
Tip
To ensure that Access will properly summarize data in your query, make sure you include only the fields you need to summarize data. For example, to determine the total number of units sold by each employee, you should include only the Employee and Units Sold fields.
Employee Abbott Carey Davis Jones Lance McMillan
9
Can I make changes to a query I created using the Simple Query Wizard?
Yes. You can use the Design view of a query to make changes to any query you create. For example, you can sort records and add and remove fields. To display a query in the Design view, see page 202.
Units Sold 8,800 7,400 3,900 3,700 7,700 8,800
Salary Employees
32" Television Products Sold by Month
Tribute Electronics : ...
The results of your query appear.
Products Sold by Mon...
¶ When you finish reviewing the results of your query, click to close the query.
12:00 PM
Tribute Electronics : ...
The query appears in the Database window. To once again open the query to review the results of the query, double-click the query in the Database window.
12:00 PM
Note: Each time you open a query, Access will use the most current data from your database to determine the results of the query.
201
CHANGE THE VIEW OF A QUERY
Design View You can view a query in five different ways. Each view allows you to perform different tasks.
SQL View
Datasheet View North
Select View
1
2
32
4
5
CHANGE THE VIEW OF A QUERY
Customer Name
Gibby Sports Inc. : D...
In this example, the query appears in the Datasheet view.
⁄ Click in this area to display the query in a different view. 202
Customer Orders Qu...
¤ Click the view you want to use.
12:00 PM
Gibby Sports Inc. : D...
The query appears in the view you selected.
Customer Orders Qu...
12:00 PM
In this example, the View button changed from to . To quickly switch between the Datasheet ( ) and Design ( ) views, click the View button.
Create Queries
9
THE QUERY VIEWS
Design View
Datasheet View
The Design view allows you to plan your query. You can use this view to specify the data you want to find, where Access can find the data and how you want to display the results.
The Datasheet view displays the results of your query. The field names appear across the top of the window. Each row shows the information for one record that meets the conditions you specified.
North
Region
SQL View
The SQL view displays the SQL statements for your query. SQL (Structured Query Language) is a computer language used to work with the information in a database. When you create a query, Access creates the SQL statements that describe your query.
PivotTable View
PivotChart View
The PivotTable view allows you to summarize and analyze the results of your query. When you first display your query results in this view, the PivotTable is empty and you must add the fields you want the PivotTable to display. For information on using the PivotTable view, see page 232.
The PivotChart view allows you to display a graphical summary of the results of your query. When you first display your query results in this view, the PivotChart is empty and you must add the fields you want the PivotChart to display. For information on using the PivotChart view, see page 238.
203
OPEN A QUERY
You can open a query to display the results of the query on your screen. Opening a query allows you to review and make changes to the query. AD3 PUSH
Each time you open a query, Access will use the most current data from your database to determine the results of the query.
COMPACT COMPACT
POWER
RESET
AD3
OPEN A QUERY
32" Television
Products Sold by Month
12:00 PM
Tribute Electronics : ...
⁄ Click Queries in the Database window.
This area displays a list of the queries in your database.
¤ Double-click the query you want to open.
204
Tribute Electronics : ...
Products Sold by Mon...
The query opens, displaying the results of the query. When you finish reviewing and working with the query, click to close the query.
12:00 PM
Note: A dialog box will appear if you did not save changes you made to the design of the query. Click Yes or No to specify if you want to save the changes.
Create Queries
e m Na st La
REARRANGE FIELDS
You can change the order of fields in a query. Rearranging fields in a query will affect the order in which the fields will appear in the query results.
Client
9
ID
Ph on e
First Na me
REARRANGE FIELDS
Product Order Details
Product Order Details
Outdoor Sporting Go...
Orders : Select Query
⁄ Display the query you want to change in the Design view. To change the view of a query, see page 202. ¤ Position the mouse directly above the field you want to move ( changes to ) and then click to select the field. The field is highlighted.
12:00 PM
‹ Position the mouse directly above the selected field and then drag the field to a new location.
Outdoor Sporting Go...
The field appears in the new location.
12:00 PM
Orders : Select Query
› Click
to save your change.
Note: A thick line shows where the field will appear.
205
ADD FIELDS
You can add one or all the fields in a table to a query. All the fields you add will appear in the results of the query.
Clien
t ID
First
Nam
e
Last
Phon
e#
Nam e
Adding a field to a query is useful if you did not include a field from a table when you created a query. ADD ONE FIELD
ADD ALL FIELDS
OrderID CompanyNa DateSold EmployeeID
ProductName
Tribute Electronics : ...
Each box in this area displays the fields for one table.
⁄ Double-click the field you want to add to your query. 206
Query1 : Select Query
12:00 PM
The field you select and the table that contains the field appear in a column.
Tribute Electronics : ...
Query1 : Select Query
12:00 PM
⁄ Double-click the heading
¤ Position the mouse
of the box for the table that contains the fields you want to add to your query.
over the selected fields and then drag the fields to the first empty column.
All the fields in the table are selected.
Each field from the table appears in its own column.
Create Queries
Why would I use the asterisk (*) to add all the fields in a table to a query?
Tip
If you may later add or delete fields from a table used in a query, you may want to use the asterisk (*) to add all the fields in the table to the query. When you add or delete a field from the table, Access will automatically add or delete the field from the query.
Tip
9
How can I clear a query to start over?
If you make mistakes while adding fields to a query, you can start over by clearing the query.
⁄ Click Edit. ¤ Click Clear Grid.
Recipe ID
Recipe Na
me
Meal
Note: If Clear Grid does not appear on the menu, position the mouse over the bottom of the menu to display the menu option.
Vegetarian
ADD ALL FIELDS USING THE ASTERISK (*)
Products.*
Tribute Electronics : ...
⁄ Double-click the asterisk (*) in the box for the table containing the fields you want to add to your query.
Query1 : Select Query
12:00 PM
The name of the table, followed by an asterisk (*), appears in a column. All the fields in the table will appear in the results of your query.
Tribute Electronics : ...
¤ To set criteria or other options for one field in the table, double-click the field to place the field in a separate column. The field appears in a separate column in the query.
Query1 : Select Query
12:00 PM
Note: To set criteria for the field, see page 211.
‹ To ensure the field will not appear twice in the query results, click the Show box for the field ( changes to ).
207
DELETE A FIELD Me al
Di Br nne Lu eak r Din nch fast n Lu nc er D h Br inne e r a Di nn kfa st er
You can delete a field you no longer want to include in your query.
re vegetarian cipes Recipe Na
me
Vegetaria
Chicken St ir-fry Bacon BLT Sand wich Lasagna Garden Sa lad Pork Chop s Pancakes BBQ Chick en
n
No No No No Yes No Yes No
When you delete a field from a query, Access will not delete the field from the table you used to create the query.
DELETE A FIELD
Department
Last Name Sales Reps
Gibby Sports Inc. : D...
⁄ To select the field you want to delete, position the mouse directly above the field ( changes to ) and then click to select the field. The field is highlighted.
208
12:00 PM
Employees Query: S...
¤ Press the
Delete
to delete the field.
key
Gibby Sports Inc. : D...
The field disappears from your query.
Employees Query: S...
12:00 PM
HIDE A FIELD
Create Queries
9
You can hide a field used in a query. Hiding a field is useful when you need a field to find information in your database, but do not want the field to appear in the results of your query. For example, you can use the State field in a query to find all your clients in Florida, but hide the State field in the query results. HIDE A FIELD
Cycle Rama
Gibby Sporting Inc. : D...
Customers Orders Qu...
Each field that displays a check mark ( ) will appear in the results of your query.
⁄ If you do not want a field to appear in the results of your query, click the Show box for the field ( changes to ).
¤ Click
to run the query.
12:00 PM
Gibby Sporting Inc. : D...
12:00 PM
If you no longer want to hide a field in the results of your query, repeat step 1 ( changes to ).
The field does not appear in the results of the query. To return to the Design view, click
Customers Orders Qu...
.
209
SORT QUERY RESULTS
You can sort the results of a query to better organize the results. Sorting the query results can help you quickly find information of interest.
r
g orde
cendin
in as ores”
sc
Sort “
You can sort the results of a query in two ways. Ascending
Sorts A to Z, 1 to 9 Descending
Sorts Z to A, 9 to 1 SORT QUERY RESULTS
14 Jack Erin Lisa Julie Alan Matt Jason Carl Simon Paul Sue Linda Frank David
Ascending
Outdoor Sporting Go...
12:00 PM
Mailing List Query : S...
⁄ Click the Sort area for
‹ Click the way you
the field you want to use to sort the results of your query. An arrow ( ) appears.
want to sort the query results.
¤ Click the arrow ( ) to list the available sort options. 210
› Click the query.
to run
Adams Baker Bell Brown Carter Cole Cook Davis Evans Fraser Grant Harris Hill Jones
Outdoor Sporting Go...
The records appear in the order you specified. In this example, the records are sorted alphabetically by state. To return to the Design view, click .
Mailing List Query : S...
12:00 PM
If you no longer want to use a field to sort the query results, repeat steps 1 to 3, selecting (not sorted) in step 3.
USING CRITERIA TO FIND RECORDS
You can use criteria to find specific records in your database. Criteria are conditions that identify which records you want to find.
ers custom Which ia? Californ
live in
?
=CA State:
?
Which students scored higher than 80% on their final grade?
Final grade: >80
?
Create Queries
9
Which reci less than 15pes take to prepare? minutes
Preparation
Time: <15
250mL 150mL 50m L
For example, you can use criteria to find all of your customers who live in California. USING CRITERIA TO FIND RECORDS
Emerald Creek Electronics
Tribute Electronics : ...
Top Customers : Sele...
12:00 PM
Tribute Electronics : ...
⁄ Click the Criteria area for the field you want to use to find specific records.
Note: For examples of criteria you can use, see page 214.
The results of the query appear.
‹ Click
¤ Type the criteria and then press the Enter key. Access may add quotation marks (" ") or number signs (#) to the criteria you type.
query.
In this example, Access found customers who ordered more than 1000 units.
to run the
Top Customers : Sele...
To return to the Design view, click
12:00 PM
.
211
USING MULTIPLE CRITERIA TO FIND RECORDS getarian Recipes Find Breakfast or Ve You can use multiple criteria to find specific records in your database.
e Name Recipe ID Recip
Meal
Vegetarian
Dinner 1 Chicken Stir-fry Breakfast 2 Bacon Lunch 3 BLT Sandwich Dinner 4 Lasagna Lunch 5 Garden Salad Dinner 6 Pork Chops Breakfast 7 Pancakes Dinner 8 BBQ Chicken
Criteria are conditions that identify which records you want to find. For examples of criteria that you can use, see page 214.
No No No No Yes
e Name Recipe ID Recip
No Yes No
2 Bacon 5 Garden Salad 7 Pancakes
Meal Breakfast Lunch Breakfast
Vegetarian No Yes Yes
250mL 150mL 50mL
USING MULTIPLE CRITERIA WITH "OR"
Hiker's Heaven
Outdoor Sporting Go...
⁄ Click the Criteria area for the first field you want to use to find specific records. Then type the first criteria.
Customers: Query: S...
12:00 PM
¤ Click the or area for the second field you want to use. Then type the second criteria. Note: You can type the second criteria in the or area of the same field or a different field.
212
‹ Click query.
to run the
Outdoor Sporting Go...
The results of the query appear. In this example, Access found customers who live in New York or Illinois.
Customers: Query: S...
12:00 PM
To return to the Design view, click .
Create Queries
Tip
How can I use multiple criteria to find specific records in my database?
You can use the Or operator to find records that meet at least one of the criteria you specify. For example, you can find employees in the Sales or Accounting department. You can use the And operator to find records that meet all of the criteria you specify. For example, you can find employees in the Sales department who earn more than $60,000.
Tip
How do I use the "And" operator in one field?
In the Criteria area for the field, type the first criteria you want to use. Then type And followed by the second criteria. For example, to find customers who purchased more than 100 units and less than 200 units, type >100 And <200 in the Quantity field.
Department Sales Sales Accounting Marketing
Department Production Sales Sales Marketing Sales
9
Field: Quantity Table: Order Details Sort: Show: Criteria: >100 And < 200 or:
Salary $57,000 $67,000 $70,000 $65,000 $50,000
USING MULTIPLE CRITERIA WITH "AND"
Outer World
Outdoor Sporting Go...
Customers: Query: S...
12:00 PM
⁄ Click the Criteria
¤ Click the Criteria
area for the first field you want to use to find specific records. Then type the first criteria.
area for the second field you want to use. Then type the second criteria.
‹ Click query.
to run the
Outdoor Sporting Go...
The results of the query appear.
Customers: Query: S...
12:00 PM
To return to the Design view, click .
In this example, Access found customers living in New York who purchased more than 50 units.
213
EXAMPLES OF CRITERIA
Here are examples of criteria that you can use to find records in your database. Criteria are conditions that identify which records you want to find. Exact matches =100
Finds the number 100.
=California
Finds California.
=3/6/2004
Finds the date 6-Mar-04.
=Date( )
Finds today's date.
Note: You can leave out the equal sign (=) when searching for an exact match.
Less than
Less than or equal to
<100
Finds numbers less than 100.
<=100
Finds numbers less than or equal to 100.
Finds text starting with the letters A to M.
<=N
<3/6/2004
Finds dates before 6-Mar-04.
Finds the letter N and text starting with the letters A to M.
<=3/6/2004
Finds dates on and before 6-Mar-04.
Greater than
Greater than or equal to
>100
Finds numbers greater than 100.
>=100
Finds numbers greater than or equal to 100.
>N
Finds text starting with the letters N to Z.
>=N
Finds the letter N and text starting with the letters N to Z.
>3/6/2004
Finds dates after 6-Mar-04.
>=3/6/2004
Finds dates on and after 6-Mar-04.
214
Create Queries
Does not match
Empty fields
Finds numbers that do not match 100.
Not 100
Finds text that does not match California.
Not California
Units
Is Null
50 75
Does Not Match
100 124 100
Is Not Null
Finds dates that do not match 6-Mar-04.
Not 3/6/2004
9
Finds records that do not contain data in the field. Finds records that contain data in the field.
Last Name Carroll Lessels Duncan Thomas
Between...And...
Find list of items In (100,101)
Finds the numbers 100 and 101.
Between 100 And 200
Finds numbers from 100 to 200.
In (California,CA)
Finds California and CA.
Between A And D
In (#3/6/2004#, #3/7/2004#)
Finds the dates 6-Mar-04 and 7-Mar-04.
Finds the letters A and D and text starting with the letters A to C.
Between 3/6/2004 And 3/12/2004
Finds dates on and between 6-Mar-04 and 12-Mar-04.
Wildcards
The asterisk (*) wildcard represents one or more characters. The question mark (?) wildcard represents a single character. Like Br*
Finds text starting with Br, such as Brenda and Brown.
Like *ar*
Finds text containing ar, such as Arnold and Marc.
Like *th
Finds text ending with th, such as Smith and Griffith.
Like Wend?
Finds 5-letter words starting with Wend, such as Wendi and Wendy.
Note: You can leave out "Like" when using wildcard characters.
215
DISPLAY HIGHEST OR LOWEST VALUES
In the results of a query, you can have Access display only the records with the highest or lowest values in a field.
Company
Product
Total Ordered
Sports R Us
Skis
898
Golf & Skis Inc.
Ski Pants
742
Ski Ski Ski!
Racing Helmet
616
#1 Skis Inc.
Ski Goggles
425
Downhill Plus
Ski Boots
306
For example, you can display the five largest orders or the ten lowest-selling products. DISPLAY HIGHEST OR LOWEST VALUES
Descending
Tribute Electronics : ...
⁄ Click the Sort area for the field you want to display the highest or lowest values for. An arrow ( ) appears.
216
Order Details Query :...
12:00 PM
¤ Click the arrow ( to display a list of sort options.
)
Tribute Electronics : ...
Order Details Query :...
12:00 PM
‹ Click the way you
Ascending
want to sort the records.
Display lowest values Descending
Display highest values
Create Queries
Tip
Why didn't the results of my query appear the way I expected?
If you have set up other fields to sort the results of your query, Access may not display the highest or lowest values in a field properly. To remove a sort from a field, perform steps 1 to 3 below, selecting (not sorted) in step 3.
9
Find Top 5 Products Sold SORTED
Product
Units Sold
Superior Race Top
4,068
Extreme Socks
3,749
Baldwin Shorts
2,562
Stay Cool Hat
2,378
Dual Purpose Shades
1,584
All 5
5
Tribute Electronics : ...
› To specify the number or percentage of records you want to display in the results of your query, click in this area. ˇ Click the number or percentage of records you want to display.
Order Details Query :...
12:00 PM
If the number or percentage of records you want to display does not appear, double-click this area. Then type the number or percentage of records you want to display.
Á Click query.
Tribute Electronics : ...
Order Details Query :...
The number or percentage of records you specified appear in the results of your query. In this example, the records with the five highest values in the field appear.
12:00 PM
To return to the Design view, click . To once again display all the records in the results of the query, repeat steps 4 and 5, selecting All in step 5.
to run the
217
PERFORM CALCULATIONS
You can perform a calculation on each record in a query. You can then review and analyze the results.
Rate/Hr
Job ID 1
8
$17.00
3
$136.00
11.5
$25.00
2
Total
Hours
$20.00
$287.50
18.2
You can use these operators to perform calculations.
$364.00 ON
4
$30.00
4
$120 7 4
5
$60.00
27.5
AC
0
+ Add
9
5
-
6
1 2 $1650
.
C
8
Subtract
* Multiply
3
/ Divide
=
^ Raise to a power
PERFORM CALCULATIONS
Tribute Electronics : ...
⁄ Click the Field area in the first empty column.
218
Order Details Query :...
12:00 PM
¤ Type a name for the field that will display the results of the calculations, followed by a colon (:). Then press the Spacebar to leave a blank space.
Tribute Electronics : ...
Order Details Query :...
‹ Type an expression that describes the calculation you want to perform. In this example, type the expression [Quantity]*[UnitPrice]. For information on entering expressions, see the top of page 219.
12:00 PM
Note: If the expression you type is too long to fit in the cell, you can zoom into the cell to display the contents of the entire cell. To zoom into a cell, see page 58.
Create Queries
Tip
9
How do I enter an expression to perform a calculation? [Quantity]*[Price]
To enter fields in an expression, type the field names in square brackets. Make sure you type the field names exactly. [Orders]![Quantity]*[Orders]![Price]
If a field exists in more than one table, you need to type the name of the table that contains the field in square brackets followed by an exclamation mark (!). Then type the field name in square brackets. Make sure you type the table and field names exactly.
MM++ MM--
RRMM
C C
1
Tribute Electronics : ...
› Click query.
to run the
Order Details Query :...
12:00 PM
Tribute Electronics : ...
The results of the calculations appear. The field name you specified appears at the top of the column.
ˇ To save the changes you made to your query, click .
Order Details Query :...
12:00 PM
To return to the Design view, click . Note: Access does not store the results of calculations in your database. Each time you run a query, Access will use the most current data in your database to perform the calculations.
219
USING PARAMETERS First Name Last Name
You can use a parameter to be able to specify the information you want to find each time you run a query.
State
Dianne
Morris
CALIFORNIA
Emily
Ross
CALIFORNIA
Matt
Cole
CALIFORNIA
Jason
Cook
CALIFORNIA
Please
Enter the state you want to view
For example, you can use a parameter to have Access request the name of the state you want to find each time you run a query.
CALIFORNIA
USING PARAMETERS
Outdoor Sporting Go...
⁄ Click the Criteria area for the field you want to use a parameter.
220
Top Customers : Sele...
12:00 PM
¤ Type an operator for the parameter. Note: For examples of operators you can use, see the top of page 221.
Outdoor Sporting Go...
‹ Type the message you want Access to display when you run the query. Enclose the message in square brackets [ ].
Top Customers : Sele...
12:00 PM
Note: If the message you type is too long to fit in the cell, you can zoom into the cell to display the contents of the entire cell. To zoom into a cell, see page 58.
Create Queries
Tip
When entering a parameter, what operators can I use? Operator
Result
=
Finds data equal to the value you enter.
>
Finds data greater than the value you enter.
>=
Finds data greater than or equal to the value you enter.
< <=
<>
Tip
9
Can I use more than one parameter?
Yes. You can enter a parameter for each field you want to use a parameter. When you run the query, Access will display the Enter Parameter Value dialog box for each parameter you entered. For example, you can enter one parameter that requests a company name and a second parameter that requests the number of orders for the company greater than a certain value.
Finds data less than the value you enter. Finds data less than or equal to the value you enter.
Display records about this company Portage Point
Company
Orders
Portage Point
70
Portage Point
78
Video Place
90
Portage Point
104
Park Radio
63
Display orders greater than this value 75
Finds data not equal to the value you enter.
Hiker's Heaven
Outdoor Sporting Go...
› Click
to run the
Top Customers : Sele...
ˇ Type the data you
query.
want to find.
The Enter Parameter Value dialog box appears, displaying the message you typed in step 3.
Á Click OK.
12:00 PM
Outdoor Sporting Go...
The results of the query appear. In this example, Access found customers who ordered more than 50 units.
‡ To save the changes you made to your query, click .
Top Customers : Sele...
12:00 PM
To return to the Design view, click . Each time you run or open the query, the Enter Parameter Value dialog box will appear, asking you to type the data you want to find.
221
SUMMARIZE DATA COMPANY
You can summarize the data in a field to help you analyze the data.
QTY ORDERED
Wild Adventures
40
Sports Inc.
60
Racquets Plus
70
Ski World
30
Bike Time Inc.
25
The Ski Club
60
Mountain Top
90
Biking Time
30
For example, you can summarize the data in the Quantity Ordered field to determine the total number of products ordered.
C RM
MM+
8
7
.
x 3
2 1
_
6
5
4
+
9
/
=
0
SUMMARIZE DATA FOR ONE FIELD
UnitsInStock
Tribute Electronics : ...
⁄ Create a query that includes only the field you want to summarize. To create a query in the Design view, see page 192.
222
Query1 : Select Query
¤ Click
12:00 PM
to display the Total row.
Tribute Electronics : ...
The Total row appears.
‹ Click the Total area for the field. An arrow ( appears.
)
Query1 : Select Query
› Click the arrow (
12:00 PM
) to display a list of calculations that you can perform.
Create Queries
What are some of the calculations I can perform to summarize data?
Tip
+ = % >– < + 1 2 3 4
Tip
Sum
Adds the values.
Avg
Calculates the average value.
Min
Finds the smallest value.
Max
Finds the largest value.
Count Counts the number of values.
Can I summarize the data for more than one field?
Yes. You can summarize the data for more than one field. For example, you can summarize the data for both the Units in Stock and Units on Order fields. When creating your query, make sure you include each field you want to summarize and specify the calculations you want to perform on the data in each field.
StDev Calculates the standard deviation of the values. Var
Calculates the variance of the values.
First
Finds the value of the first record entered.
Last
Finds the value of the last record entered.
9
Product
Units in Stock Units on Order
Hockey Gloves Hockey Stick Hockey Helmet Hockey Shin Pads Skates Putter Golf Driver Golf Glove Skis Ski Poles Ski Boots
25 125 50 21 45 33 21 45 22 24 35
15 59 10 5 15 25 9 23 10 12 8
10850
Sum
Tribute Electronics : ...
ˇ Click the calculation that you want to perform on the data in the field. Note: For information on some of the calculations that you can perform, see the top of this page.
Query1 : Select Query
Á Click query.
12:00 PM
to run the
Tribute Electronics : ...
The result of the calculation appears. In this example, Access calculates the total number of units in stock for all products. To return to the Design view, click .
Query1 : Select Query
12:00 PM
If you no longer want your query to summarize the data in a field, repeat step 2 to remove the Total row from your query.
223
SUMMARIZE DATA
Date
You can group records in your database and summarize the data for each group.
May 12, 2004 May 13, 2004
May 14, 2004
May 15, 2004
Qty Ordered 105 200 100 150 92 300 100 94 250 104 304
405 242 744 For example, you can group records by date and determine the total number of orders for each day.
408
SUMMARIZE DATA FOR GROUPED RECORDS
UnitsInStock
Sum
Tribute Electronics : ...
⁄ Create a query that includes only the field you want to use to group your records and the field you want to summarize. To create a query in the Design view, see page 192. 224
Query1 : Select Query
¤ Click Total row.
12:00 PM
to display the
The Total row appears.
Tribute Electronics : ...
Query1 : Select Query
12:00 PM
‹ Click the Total area for the field you want to summarize. An arrow ( ) appears.
ˇ Click the calculation
› Click the arrow (
Note: For information on some of the calculations that you can perform, see the top of page 223.
) to display a list of calculations that you can perform.
that you want to perform on the data in the field.
Create Queries
Tip
9
Can I use more than one field to group records? COMPANY
Yes. You can group records using more than one field. For example, to determine the total amount of each product purchased by each company, use the Company and Product fields to group records and the Quantity Ordered field to summarize data. When creating your query, make sure you place the fields in the order that you want to group the records. Access will group the records using the fields from left to right.
PRODUCT
QUANTITY ORDERED
Fitness Minds
A
40
Fitness Minds
B
60
Racquets Plus
A
80
Racquets Plus
B
30
Ski World
A
25
Ski World
B
60
SportStop
A
90
SportStop
B
100
Camcorder
Sum
Tribute Electronics : ...
Access will group the records using the field that displays Group By.
Query1 : Select Query
Á Click query.
12:00 PM
to run the
Tribute Electronics : ...
Query1 : Select Query
12:00 PM
The results of the calculations appear.
To return to the Design view, click .
In this example, Access calculates the total number of units in stock for each product.
If you no longer want your query to summarize the data for grouped records, repeat step 2 to remove the Total row from your query.
225
FIND UNMATCHED RECORDS 5 ss ID Addre me First Na me Last Na ss Addre
ie Melan 5 son Robin es. nold Cr ie 26ssArID Melan 5 Addre n me binso . First Na sonville Ro es Cr Jackme nold ie 26ssArID Last Na Melan 5 Addre FLss son City inceAddre 6 First Name nville Robin . ov es Pr 25 Cr so 32 Jackme State/ nold ie 26ssArID Last Na Melan 8 l Code Addre USA Posta FLss son City inceAddre 6 First Name nville Robin . try ov hn es un Pr Jo 25 Cr so Co 32 Jackme nold me State/ 26ssArID se Na Last Na Sue l Code Addre USA Spou Posta FLss City inceAddre 6 First Name nville Grant . try ov hn es un Pr Jo 25 Cr so Co 32 Jackme nold me State/ 26 Ar se Na Last Na l Code USA Spou Posta City e FLss le try hnovinc Addre 2256 Jo/Pr Coun k onvil
You can use the Find Unmatched Query Wizard to find records in one table that do not have matching records in another table.
ched Mat rds Reco
5 s ID Addres me First Na me Last Na s es dr Ad
Linda Harris . ld Cres 26 Arno nville
Jackso City ovince State/Pr Code Postal C ntry
ers Ord
FL 32256 USA
ers m o t Cus
For example, you can find all customers who have not placed an order.
FIND UNMATCHED RECORDS
Create query in Design view
Find Unmatched Query Wizard
12:00 PM
Outdoor Sporting Go...
⁄ Click Queries in the Database window.
¤ Click New to create a new query.
Outdoor Sporting Go...
The New Query dialog box appears.
‹ Click Find Unmatched Query Wizard.
226
12:00 PM
› Click OK to continue.
Create Queries
Tip
Why does a dialog box appear when I select the Find Unmatched Query Wizard?
When you select the Find Unmatched Query Wizard for the first time, a dialog box appears, stating that the wizard is not installed on your computer. To install the wizard, click Yes.
Tip
9
How can I prevent unmatched records from being entered in two tables?
You can enforce referential integrity between two tables to prevent you from entering a record in one table if a matching record does not exist in a related table. For example, if a customer does not exist in the Customers table, you will not be able to enter an order for the customer in the Orders table. For more information on referential integrity, see page 132. CUSTOMERS Company Name
ID
Address
City
State Postal Code
Boston Cycles
2
258 Linton Ave.
New York
NY
Racquets & Stuff
3
50 Brittania Lane
Boston
MA
Las Vegas
NV
Greg’s Pet Store ORDERS Order #
ID
4 47 Crosby Ave
Company Name
Product
Qty
1
Sport City
Running Shoes
2
Boston Cycles
Water Bottle
11
$8.00
13400
3
Racquets & Stuff Tennis Balls
15
$18.00
15309
4
12
$20.00
Pet Superstore
Vitamins C
02117 89116
Unit Price
12340 13609
S
7
10010
$3 $3.50 50
$
Table: Customers
Table: Order Details
Outdoor Sporting Go...
The Find Unmatched Query Wizard appears.
ˇ Click the table that contains the records you want to display in the query results if another table does not have matching records.
12:00 PM
Á Click Next to continue.
Outdoor Sporting Go...
‡ Click the table that contains the matching records.
° Click Next to continue.
12:00 PM
You can click Back at any time to return to a previous step and change your selections.
227
FIND UNMATCHED RECORDS
Customer ID
When using the Find Unmatched Query Wizard, you need to select the field that appears in both tables so Access can compare the data in the tables.
Customer ID
86
86
Customers
Orders Address87
Customer ID
City
State/Province Postal Code
86
62 Cracker Ave. San Francisco CA
87
57 Crosby Ave. Las Vegas
88
Customer ID
Product
87
94110
86
Wet Suit
NV
89116
87
Surfboard
23 Bizzo Dr.89 New York
NY
10020
88
Roller Blades
89
12 Goldmar Ave. Las Vegas
NV
89116
89
Skates
90
26 Arnold Cres. Jacksonville
FL
32256
90
Water Skis
91
401 Idon Dr.
TN
37243
91
Volleyball
92
10 Heldon St. 92 Atlanta
GA
30375
92
T-ball Stand
93
35 Pine St.
Baltimore
MD
21233
93
Tennis Racquet
New York
88
90 91
93
Nashville
88 89 90 91 92
Quantity
Unit Price
Last Order
50
$175.00
5/12/97
20
$325.00
11/5/96
45
$225.00
5/12/97
35
$85.00
4/18/95
25
$300.00
9/12/96
30
$40.00
8/22/97
5
$55.00
6/5/96
100
$125.00
1/14/97
94
87 King St.
NY
10199
94
Hockey Stick
93
200
$35.00
8/18/97
95
56 Yemen Blvd. San Francisco CA
94188
95
Running Shoes 94
160
$130.00
11/25/95
94
95
For example, you can select the Customer ID field in the Customers and Orders tables.
95
FIND UNMATCHED RECORDS (CONTINUED)
Zip Code State Company Name
Company Name
12:00 PM
Outdoor Sporting Go...
· Click the field in the first table that also appears in the second table.
— Click
to confirm your selections.
± Click Next to continue.
Outdoor Sporting Go...
This area displays the fields from the table you selected in step 5.
¡ Double-click each field
‚ Click the matching field in the second table.
you want to appear in the results of your query.
Note: The matching fields will usually have the same name.
Note: To add all the fields in the table at once, click .
228
12:00 PM
Each field you select appears in this area. To remove a field you accidentally selected, double-click the field in this area.
™ Click Next to continue.
Create Queries
Tip
Do I have to recreate a query each time I want to find unmatched records in the tables?
Tip
No. Each time you open a query you created using the Find Unmatched Query Wizard, Access will use the most current data from the tables you specified to determine if any unmatched records exist in the tables.
9
Can I change data displayed in the results of my query?
Yes. You can change data displayed in the results of a query as you would edit data in a table. If you change the data displayed in the query results, the data will also change in the table you used to create the query. To edit data in a table, see page 56.
Orders Table
Customers Table
Table
Query
$60
QU ER Y
$60
American Outdoors
Outdoor Sporting Go...
£ Type a name for your query.
12:00 PM
¢ Click Finish to display the results of your query.
Outdoor Sporting Go...
The results of your query appear. In this example, Access displays information about each customer who has not placed an order.
Customers Without O...
12:00 PM
∞ When you finish reviewing the results of your query, click to close the query.
229
PivotTable
Region Central
North
South
Quarter 1 + Sales + -
+ -
+
-
0 $29,000.0 0 .0 0 0 ,0 $16
Quarter 2
+-
Sales
0 $19,000.0 0 .0 0 0 ,0 $19 s n Cai $14,600.00
$18,000.00 $15,000.00 $16,000 Pat .0$021,000.00 $202 0 .0 0 0 ,0 $23 $22,000.0 ,900.00 0 .0 0 0 0 ,5 3 $2 $19,000.0 0 .0 0 0 ,9 8 $2 $19,400.00 $17,300M.00 engle 0 .0 0 0 0 .0 $19,5 $18,200 0 $12,400.0 000.00 y 100.00 pe1,ars San$1d9, S$2 0 .0 0 $21,0o
CHAPTER 10
Using the PivotTable and PivotChart Views Are you interested in analyzing and summarizing data in your database? In this chapter, you will learn how to use the PivotTable and PivotChart views to work with your data. Using the PivotTable View ................232 Using the PivotChart View ................238
USING THE PIVOTTABLE VIEW ble PivotTa
You can use the PivotTable view to summarize and analyze the data in a table, form or the results of a query.
When you first display a table, form or query in the PivotTable view, the PivotTable may appear empty. You may need to add the fields you want to display to the PivotTable. If you have previously displayed the table, form or query in the PivotChart view, the PivotTable will display the fields you added to the PivotChart. For information on the PivotChart view, see page 238.
USING THE PIVOTTABLE VIEW
Grant Lewis Smith Grant Lewis Smith Grant Lewis Smith Fraser Turner Morris Turner Fraser Turner
Gibby Sports Inc....
⁄ To show the displayed table, form or query in the PivotTable view, click in this area.
232
Employee Sales
Employee Sales : ...
12:00 PM
¤ Click PivotTable View.
Gibby Sports In...
Employee Sales ...
The table, form or query appears in the PivotTable view. The PivotTable Field List dialog box also appears, displaying the name of each field in your table, form or query.
12:00 PM
If the PivotTable Field List dialog box does not appear, click to display the dialog box.
Using the PivotTable and PivotChart Views
Tip
10
What fields do I need to add to create a PivotTable? Period Quarter 1
Quarter 2
Region
Sales
Sales
Sales
Central
$16,000.00 $29,000.00 $16,000.00 $15,000.00 $17,300.00 $28,900.00
$19,000.00 $19,100.00 $23,000.00 $22,900.00 $19,400.00 $19,500.00
$18,000.00 $14,000.00 $21,000.00 $23,500.00 $18,200.00 $12,400.00
North South
Quarter 3
Grand Total No Totals
Grand Total
Totals or Detail Field
Row Field
Column Field
Specifies a field that contains the data you want to summarize in the table.
Specifies a field you want to use to group data in the table. The name of each group in the field appears down the left side of the table.
Specifies a field you want to use to group data in the table. The name of each group in the field appears across the top of the table.
Sales
Gibby Sports Inc....
Employee Sales : ...
‹ To add a field that contains the data you want to summarize in the table, position the mouse Œ over the name of the field in this area.
12:00 PM
› Drag the field name to the Drop Totals or Detail Fields Here area.
Gibby Sports Inc....
The name of the field you selected appears in this area.
Employee Sales : ...
12:00 PM
This area displays the data for each record in your table, form or query.
233
USING THE PIVOTTABLE VIEW
PivotTable When using the PivotTable view, you can select the fields you want to use to group the data in the PivotTable.
Region Central
North
South
Quarter 1 + Sales + -
+ -
+
-
$29,000.00 $16,000.00
Quarter 2
+-
Sales
$19,000.00 $19,000.00
Cains $14,600.00 $18,000.00 00 0. 00 5, $1 $16,000 Pat .0$2 0 1,000.00 $202 $23,000.00 $22,000.0 ,900.00 0 .0 0 0 0 ,5 3 $2 $19,000.0 0 $28,900.0 $19,400.00 $17,300M.00 engle 0 .0 0 $19,50 $18,200.00 $12,400.00 000.00 y 00.00 pe1,ars San$1d9,1 S$2 0 .0 0 o ,0 1 $2
For example, you can use the Region field to group the data by region in the PivotTable.
USING THE PIVOTTABLE VIEW (CONTINUED)
Region Period
Gibby Sports In...
ˇ To add the field you want to use to group the data in the table, position the mouse over the name of the field in this area.
234
Employee Sales ...
12:00 PM
Á Drag the field name to the Drop Row Fields Here area.
Gibby Sports Inc....
Employee Sales : ...
The name of the field you selected appears in this area. The name of each group in the field appears down the left side of the table.
‡ To add another field you want to use to group the data in the table, position the mouse over the name of the field in this area.
12:00 PM
° Drag the field name to the Drop Column Fields Here area.
Using the PivotTable and PivotChart Views
Tip
Can I remove a field from a PivotTable?
Tip
Yes. You can remove any field you added to a PivotTable. Removing a field from a PivotTable will not remove the field from the table, form or query used to create the PivotTable. To remove a field from a PivotTable, click the name of the field in the PivotTable and then press the Delete key. Period Quarter 1
Quarter 2
Sales
Sales
Sales
$16,000.00 $29,000.00 $16,800.00 $15,000.00 $17,300.00 $28,900.00
$19,000.00 $19,100.00 $23,000.00 $22,900.00 $19,400.00 $19,500.00
$18,000.00 $14,600.00 $21,000.00 $23,500.00 $18,200.00 $12,400.00
South
Gibby Sports Inc....
The name of the field you selected appears in this area. The name of each group in the field appears along the top of the table.
To move the PivotTable Field List dialog box, position the mouse over the title bar of the dialog box and then drag the dialog box to a new location.
Employee Sales
Central North
How can I move the PivotTable Field List dialog box so it does not cover my PivotTable?
Quarter 3
Region
Employee Sales : ...
The name of each field you added to the table appears in bold in the PivotTable Field List dialog box.
12:00 PM
10
Gibby Sports Inc....
Employee Sales
Employee Sales : ...
12:00 PM
Each group of data displays a plus sign ( ) and a minus sign ( ).
· To save all the changes you made in the PivotTable view, click .
To hide the data in a group, click a minus sign ( ).
Note: Access automatically saves changes you make to a form displayed in the PivotTable view.
Note: To once again display the data in a group, click a plus sign ( ).
235
USING THE PIVOTTABLE VIEW
You can perform calculations on the data displayed in a PivotTable to help you analyze the data.
Quarter 1 Sales
Quarter 3 Sales
Quarter 2 Sales
+
+
$18,000.000
Grand Total
=
Central
$16,000.00
North
$16,000.00
$23,000.00
$21,000.00
$60,000.00
South
$17,300.00
$19,400.00
$18,200.00
$54,900.00
Grand Total
$49,300.00
$61,400.00
$57,200.00
$167,900.00
$19,000.00
$53,000.00
PERFORM CALCULATIONS
Gibby Sports In...
⁄ Click the name of the field in the table that contains the data you want to perform calculations on.
236
Employee Sales ...
The data in the field is highlighted.
12:00 PM
Gibby Sports In...
¤ Click
to display a list of the calculations that you can perform.
Employee Sales ...
12:00 PM
‹ Click the calculation you want to perform. Note: For information on the calculations that you can perform, see the top of page 237.
Using the PivotTable and PivotChart Views
Tip
10
What calculations can I perform on the data in a PivotTable?
+ = % ->< + 1 2 3 4
Calculation:
Result:
Sum
Adds the values.
Count
Counts the number of values.
Min
Finds the smallest value.
Max
Finds the largest value.
Average
Calculates the average value.
Standard Deviation
Calculates the standard deviation of the values.
Variance
Calculates the variance of the values.
Standard Deviation Population
Calculates the population standard deviation of the values.
Variance Population
Calculates the population variance of the values.
Sum of Sales
Delete
Gibby Sports In...
The table displays the subtotals and grand totals for the calculation you selected. The name of the new total field appears at the top of the PivotTable Field List dialog box.
Employee Sales ...
12:00 PM
Gibby Sports Inc....
Employee Sales : ...
12:00 PM
› To save the change you
REMOVE CALCULATIONS
¤ Click Delete.
made in the PivotTable view, click .
⁄ To remove calculations
The field will disappear from the PivotTable Field List dialog box and the calculations will disappear from the table.
Note: Access automatically saves changes you make to a form displayed in the PivotTable view.
from a table, right-click the name of the total field in the PivotTable Field List dialog box. A menu appears. If the PivotTable Field List dialog box does not appear, click to display the dialog box.
237
USING THE PIVOTCHART VIEW
Sales: Table
You can use the PivotChart view to display a graphical summary of the data in a table, form or the results of a query.
Invoice Nu mb
er
Last Name
23452 Gra nt 23453 Le wis 23454 Sm ith
Sum of Sales $124,000.00 $122,000.00 $120,000.00 $118,000.00 $116,000.00 $114,000.00 Central
North
Region
No rth So uth Ce ntr No al rth So uth Ce ntr No al rth So uth Ce nt Ce ral ntr No al rth So u No th rth
Sales
.00 ,000 $15 0.00 0 ,4 $12 .00 ,000 $19 0.00 0 9 , $22 .00 ,900 $28 0.00 0 ,0 $18 0.00 ,00 $21 0.00 ,50 $19 0.00 ,00 0 9 2 $ .0 ,000 0 6 $1 0.0 0 8 , $16 0.00 ,20 $18 0.00 ,00 3 $2
South
Region
When you first display a table, form or query in the PivotChart view, the PivotChart may appear empty. You may need to add the fields you want to display to the PivotChart. If you have previously displayed the table, form or query in the PivotTable view, the PivotChart will display the fields you added to the PivotTable. For information on the PivotTable view, see page 232.
USING THE PIVOTCHART VIEW
Grant Lewis Smith Fraser Turner Grant Lewis Smith Fraser Turner Grant Lewis Smith Fraser
Winston Sports I...
Employee Sales
Employee Sales: ...
⁄ To show the displayed table, form or query in the PivotChart view, click in this area.
238
12:00 PM
¤ Click PivotChart View.
Winston Sports I...
Employee Sales: ...
The table, form or query appears in the PivotChart view. The Chart Field List dialog box also appears, displaying the name of each field in your table, form or query.
12:00 PM
If the Chart Field List dialog box does not appear, click to display the dialog box. Note: If is not displayed, click on the PivotChart toolbar to display the button.
Using the PivotTable and PivotChart Views
Tip
10
What fields do I need to add to create a PivotChart? Category Field
Specifies a field you want to use to group data in the chart. The name of each group in the field appears along the bottom of the chart.
Series Field
Data Field
Specifies a field that contains the data you want to summarize in the chart. Access will plot the summary of the data in the chart.
Specifies a field that contains the data you want to display as separate data series in the chart. Each data series is represented by a specific color, which is identified in the legend.
Region
Winston Sports I...
‹ To add the field you want to use to group data in the chart, position the mouse over the name of the field in this area.
Employee Sales: ...
Region
12:00 PM
› Drag the field name to the Drop Category Fields Here area.
Winston Sports I...
Employee Sales: ...
The name of the field you selected appears in this area. The name of each group in the field may appear along the bottom of the chart.
12:00 PM
Note: The name of each group in the field may not appear in the chart until after you perform step 6.
239
USING THE PIVOTCHART VIEW
When using the PivotChart view, you can select the field that contains the data you want to summarize in the PivotChart.
Chart Field List
$124,000.00
Drag items to
Sum of Sales
$122,000.00 $120,000.00 $118,000.00 $116,000.00
$114,000.00
Central
North
South
the Chart Employee Sales Invoice N umber Last Nam e Region Period
Sales
Access will plot the summary of the data in the PivotChart. For example, Access will display the total sales for each region.
PUSH
USING THE PIVOTCHART VIEW (CONTINUED)
Sales Period
Winston Sports...
Employee Sales...
ˇ To add the field that contains the data you want to summarize in the chart, position the mouse over the name of the field in this area.
12:00 PM
Á Drag the field name to the Drop Data Fields Here area.
Winston Sports...
The name of the field you selected appears in this area. Access summarizes the data for each group in the chart.
Employee Sales: ...
12:00 PM
‡ To add a field that contains the data you want to display as separate data series in the chart, position the mouse over the name of the field in this area. ° Drag the field name to
240
the Drop Series Fields Here area.
Using the PivotTable and PivotChart Views
Tip
Can I remove a field from a PivotChart?
Tip
Yes. You can remove any field you added to a PivotChart. Removing a field from a PivotChart will not remove the field from the table, form or query used to create the PivotChart. To remove a field from a PivotChart, click the name of the field in the PivotChart and then press the Delete key.
10
How can I move the Chart Field List dialog box so it does not cover my PivotChart?
To move the Chart Field List dialog box, position the mouse over the title bar of the dialog box and then drag the dialog box to a new location.
Employee Sales : Table
60000
Sales
Sum of Sales
40000 Pe rio d Qu ar te Qu r ar te 1 Q
Period
20000
Quarter 1 Quarter 2 Quarter 3
0 Central
North
South
Region
Period
Period
Winston Sports...
The name of the field you selected appears in this area. Access displays a data series for each group of data in the field.
Employee Sales...
12:00 PM
· To display a legend that identifies the color used for each data series in the chart, click .
Winston Sports...
Employee Sales...
The legend appears. Note: To remove the legend, click again.
‚ To save all the changes
12:00 PM
Note: Access automatically saves changes you make to a form displayed in the PivotChart view.
you made in the PivotChart view, click .
241
USING THE PIVOTCHART VIEW
You can change the chart type of a PivotChart to present your data more effectively.
CHANGE THE CHART TYPE
Winston Sports...
⁄ Click a blank area in the chart you want to change to a different chart type.
242
Employee Sales...
12:00 PM
Winston Sports...
12:00 PM
Employee Sales...
to change the chart type.
‹ Click the type of chart you want to use.
› Click the chart design
The Properties dialog box appears.
This area displays the available chart designs for the type of chart you selected.
Access changes the chart type of the chart.
¤ Click
you want to use.
ˇ Click
to close the Properties dialog box.
Using the PivotTable and PivotChart Views
Average of Sales
Average
Average
Average
Average
Average Average
Average
Average
Average
Sum
Sum
Sum
Sum
Sum
Sum
Sum
Sum
Sum of Sales
Sum
You can change the type of calculation that Access performs on the data in a PivotChart to help you better analyze the data.
10
For example, Access can calculate the average value for each group in a PivotChart. CHANGE THE CALCULATION PERFORMED
Winston Sports...
Employee Sales: ...
12:00 PM
⁄ Click the name of
‹ Click the calculation
the field in the chart that contains the data that Access has summarized in the chart.
you want to perform. Note: For information on the calculations that you can perform, see the top of page 237.
Winston Sports...
Employee Sales...
12:00 PM
The chart shows the results of the calculation you specified.
¤ Click
to display a list of the calculations that you can perform.
243
le 2 Tab Table 1
Table
3
CHAPTER 11
Create Reports Would you like Access to help you present your data in a neatly organized report? This chapter teaches you how to create and work with reports. Create a Report Using the Report Wizard ........................................246
REPORT Order Details
Create a Report Using an AutoReport ..................................254
1
OrderID e Company Nam e Product Nam Unit Price
Ski World ski goggles $42.00 100
Quantity
2
OrderID e Company Nam e Product Nam Unit Price
$50.00 50
Quantity OrderID e Company Nam e Product Nam
Open a Report................................256
Inc. Big League T-ball stand
Move Through Pages ......................257
3 Varsity Supply lacrosse stick
Unit Price Quantity OrderID e Company Nam e Product Nam Unit Price Quantity OrderID e Company Nam e Product Nam Unit Price Quantity
$75.00 70
Change the View of a Report ..........258
4 Ski World snowboard $360.00
Zoom In or Out ..............................260
30
5 rts Stadium Spo all leather footb $45.00
Apply an AutoFormat ......................261
90 Page 1 of 2
h 2, 2002 Saturday, Marc
Com pan Ski y Na Wor me ld Big Leag u e Vars Inc. ity Ski W Supply orld Stad ium Sp Risk y W or ts hee Surf lz ers Indo Appare or S l por t Spo s kes 'n ' Stuf Wav f erid er
Add a Picture..................................262
e
ric it P
Un
0 2.0 0 $4 0 . 0 0 $5 5.0 0 $7 .0 0 6 0 $3 45.0 $ .00 0 $4 0.00 6 0 $3 0.0 0 $4 0 . 0 $4 .00 90 $2
CREATE A REPORT USING THE REPORT WIZARD
Table
Table 1
You can use the Report Wizard to create a professionally designed report that summarizes data in your database. 3
le Tab
2
Tuesday, February 24,
2004
The Report Wizard asks you a series of questions and then creates a report based on your answers.
CREATE A REPORT USING THE REPORT WIZARD
Create report by using wizard
Table: Products
12:00 PM
Tribute Electronics : ...
⁄ Click Reports in the
¤ Double-click Create
Database window.
report by using wizard.
The Report Wizard appears.
‹ Click
in this area to select the table that contains the fields you want to include in your report.
246
12:00 PM
Tribute Electronics : ...
› Click the table that contains the fields.
Create Reports
Tip
Which tables in my database can I use to create a report?
Tip
11
Can I create a report using data from a query?
Yes. When creating a report, you can use data from queries. The Report Wizard allows you to select the fields you want to include from queries as you would select the fields you want to include from tables. For information on queries, see pages 192 to 229.
You can use any table in your database to create a report. When creating a report that uses information from more than one table, relationships must exist between the tables so that Access can bring together the information in the tables. For information on relationships, see page 128. e taleCod PosCod e tal Code e incPos te/Pincrov 10 e10Postal Starov te/P Code 100 rovinc Postal y Sta te/P100 Code ince10 City Cit NY Sta 021te/P 17rov17100 Postal e s Sta 021 k CitNYy 100 ince10 tal Cod Adds res YorwkYor Addres 10021rov17 100 MAy NY e Pos State/P Ne 941 resw. sNe MAk Cit . Ave 17 inc10 94110 me Yor NY t Name Ave tonAdd 021rov Na w n y t Las s Lin ton Cit sto Sta10te/P . Ne Lin 10010 258 Bonres stoAve York MA me Las NY 16941 t Name 891 etonAdd 02117 h 258 nCAw CA sco 891 City16 LinBo . sNe NastmeNa nci hmitLas eeLan sto res k MA sco 94110 stFir me Lan Ave 258 Bo Fra Tre Fir mit nci e Na 16 Sch Yor Add NY t CA me ton w 02117 50 Tre Sch e San ns Lin Ne . Fra NV 50hLas ID s ID MA56891 . sco sto San Lan res k322 .eAve NVnci First Na ttenme me Bo Ave 1694110 322 Adds res rsonmit Yor56 Add Na Trer258 tAve asFra r cke eton Addres Na Sch rso 50 ID nNewCA 10 hCra Las as San sco Veg Lin cke ttestPe MA56891 Lan . . Jim1s Jim NV sto Fir mit nci e Pe 941 68 Veg res 1 Cra me 322 Las n 43 258 Ave Bo Ave 16 FL Fra Tre .r Sch 68 CA Add rso t Na Las 372 ton FL e as ID .50 cke Ave tteme San n 43 56891 s Jim lle Lin h Las 372 .Veg sco NV Lan Cra Ave res1nda sby nvi botstPeNa n68 lle Fir mit Bre e258 Ave 16 2nda r Las sby Cro Add nvi CA43322 me Sch FLBoncisto sco75372 .kso 2 Bre ckeTre 47rso TalbotTal Cro Jac Na 50 ID SaneasFra 56 891 Ave sJim Pesttte Cra s.hkso .Veg lleTN NV Jac Fir47 mit res1nda 75 e Lan 303 TN sby nvi Cre s.n68 bot Ave 43322 r Las Franci Tre 2dBre Sch rso Cro old asFL303 d Add cke 50 tte47Cre ille.kso Jim Jac s IDanTal Arn De lle . San an NV75372 1nda Cra ille shvAve TN s. sby 32256 26Peold 3 Tod3 Tod 2dAdd Arn Deres nNa Bre AveVeg 68 shv Las Cre r nvi Talbot Cro kso FL 18303 . GA Narso as 18 021 37243 tteold 47 Jac an26 GA Jim Tod Ave illecke son Dr.
75 TN Veg nda 021 1De Cra 3 s.shv Arn bin son Dr.nPe Chuck nville 68 Bre 26 Ido asby Na d Ro FL18303 Talnbot .GALas antCre old aCro Ro2bin 4 Ch4uck 37243 401 ille 47Atl Jac Avekso ant 3 Tod De nda lle 20021 sonanIdo Dr. TN s. MA shv 20 100 nArn sby 26 bot bin401 Na St.Atl Cre 1830375 100nvi ie4lanChieuck Hu aMA Cro d2RosBre GA St.TalnIdo sghe 47 ann401 ldo Jackso ille noldant son Dr.Atl 3gheTod TN20021 He s.MA ldo sto 5 Me5lanMe Hu 26 30375 ie uck He10De BonArn Na sto aCreshv Ro 4 Ch St. ds bin GA 21100 BonIdo antNY 921 an St. ghe10 ille21 2002118 Atl ldo nNYold 3HusTod son Arn De rd401 5 Melan Ch MA 921 St. kDr. He pin iesuck Susan bin 26nsto rd10zza Yor kSt. sBu aNashv Bo 4pin Top zza GA21100 YorwnIdo 6 Su6san 02118 Bu36Ro Toplan Ne ldo n antNY St. 5 Me Atl son Hus ghe 36 CA uck MA32921 NeHe 900 rdw401 san kn Dr. bin 10020 ieCh CAsto y pin Bo zza Ido 900 a 32 St. Pl.10 4Top NY n Yor Bu enn ant wgo zosRo Pl. ghe 401 92121 Meylan nAlle6nSu St. ldo 36 32 n Atl Ne enn s 5 Biz Kilk 7 zo Hu Die go rd san MA He Alle k CA sto pin 10020 15 900 ie Biz Su Kilk 7 zza Die San BoSt. CA s 10 6n lan Bu 15 Topy NY 67 Pl. w nYor 303 CA ghe Meenn 3292121 zoSan Ne St. ldo go n 67 St. es son Hu 303 sBiz36 rdHe san CA Die rcu5Kilk es ple pin g 7g Alle Ma6nrcu Suson zza 10gel 15St. y Ap Boksto gel Ma Yor Pl.An ple San NY67900 CA Bu Top w An enn Ap zo Los 8 Gre8 Gre 7g Alle go 92121 890 303 St. 10 36 . 32 Ne s Biz GA Kilk St. es son Die Los san 890 CA k902 Ave 15.pin gelrd GA zza ple 67900 San yge Yor10 902 An Bu Ap Top 8onGre n6MaSurcu ula wCA ulaAve enn zo 36 a Pl. Los Allertin Goge 890 son Ma Die ant.St. CA10303 GANego 39CA 39902 aBiz 90032 18Kilk geles Go rcu 9 Jas9onJas 8onGre ple Ave 15Atl Ma7grtin ant y An 67 Ap San 18 CA Ma Pl. ge n 900 Atl s enn . CA zo 303 Los go ula 10 Alle .St. 900 rtin lsa ew Biz Go GA Kilk 9 Jas Ave890 Die gs7Ma Hil lspleant Ave ewtth geles rcu 15 18t.son Ave Gre 67 Atl AnSan tLen CA39902 erly Ap 8tthMa 10 Jim 9 Jas Maon ula s11Ma erly rtin Bev Los . geHil 890 10 Jim 10 303 .CA Go es 70900 70 son 019 lsaSt. CA 019 gewLen 11 Ma GA Bev ant en CA Ave s. 18 gel Ave rcu Hil tth 902 ple 39 t Gre Atl es hle An Jim en Cre s. ge Ap CA Ma Ma f 8 on gelerly es Kat10 ula Cre .890 f tof Jas erly 11 Len 18 gelAn ls.aLos Bev ew 11hle Go 9 Ra GA70900 Ovsrtin Ma Hil ttherly antCA ts.Ave Los 90210 Ra 11 Kat entof AtlAve ge esMA Los Len on CA 019 CreAn f Ov4 St. 7090039 ula s11 gelerly St. rtin Kat10hleJim enltfau .MA Bev tof4Ma ltJas a CA erly Go ls An ew 9 019 n Ma Ra 11 Ave llow ant Ov Hil tth s. 18 t Ro 39 n emLos Wi4 es Jim fau MAAtl llow Thy Cre gel em Wi13fMa 10hle sSalLen Thy . erly 11 12 Ro12 St. AnBev Sal 13 CAls CA Ralttof 11n Kat 01970 900 Ovewerly St. Los en fau s.t Ave llow MA Jim St. es Ma em Wi4tth hle Len erly Hil CA Cre lfe futh 10Thy 12nRo 11 So gel nJoh uth Sal 13 St. Kat 11 tof Bev Wo lfe lt erly An So 13 Joh Ra 01970 486 n Ov Wo llow Loss. 13 es Thyenfau hle l n Ro fWi4St. 12 SalemCre 13 gelMA lfe486 an Kat tofuth St. Joh lt So 11Wo St. 13l hae Mic 486Ra fau llow Bat 4 Overly Salem Los An Roannem MA 14hae Wi nem uth Thy Bat lfe 12 l So 13 14 Mic Joh St. an Wo 13hae fault em Thy486 nBatRoemn Wo uthWiSt.llow l 12 liseDe14liseMic emanlfe 486 So13 uth St. Sal 15 De15 Mic13haeJoh l Bat lise 14 n an lfe haeJoh 15 De 486 So Batem Wo an liseMic13 15 De14 hael Batem lise Mic 15 De 14 lise 15 De
LES TAB
Query: Employee Sales Query
ProductName Employee ID Order Date
Tribute Electronics : ...
This area displays the fields from the table you selected.
12:00 PM
ˇ Double-click each field you want to include in your report. Note: To add all the fields in the table at once, click .
Tribute Electronics : ...
Each field you select appears in this area. To remove a field you accidentally selected, double-click the field in this area. Note: To remove all the fields at once, click .
12:00 PM
Á To include fields from other tables in your database, repeat steps 3 to 5 for each table. ‡ Click Next to continue.
247
CREATE A REPORT USING THE REPORT WIZARD
You can choose how you want to group data in your report. Grouping data helps you organize and summarize the data in your report.
For example, you can group data by the State field to place all the customers from the same state together in your report. CREATE A REPORT USING THE REPORT WIZARD (CONTINUED)
by Order Details UnitPrice
12:00 PM
Tribute Electronics : ...
If you selected fields from more than one table, you can choose the way you want to group the data in your report. Note: If this screen does not appear, skip to step 10.
248
° Click the way you want to group the data in your report. This area shows how Access will group the data in your report.
· Click Next to continue.
Tribute Electronics : ...
‚ To use a specific field to group data in your report, double-click the field you want to use. This area shows how Access will group the data in your report. The field you selected appears in blue.
12:00 PM
To remove a field you accidentally selected to group data in your report, double-click the field in this area.
— Click Next to continue.
Create Reports
Tip
11
Why would I sort the records in my report?
You can sort the records in your report to better organize the data. For example, you can sort records alphabetically by the Last Name field to make it easier to find customers of interest. If the same last name appears more than once in the field, you can sort records by a second field, such as First Name, to further organize the data. You can use up to four fields to sort the records in a report.
Ada m Smi s th Smi th Smi th You ng
Jack Alic e Bob Cra ig Jane t
Order Date
Order Date
Tribute Electronics : ...
± To sort the records in your report, click in this area. Note: For information on sorting, see the top of this page.
12:00 PM
Tribute Electronics : ...
12:00 PM
¡ Click the field you
™ Click this button until the
£ To sort by a second
want to use to sort the records.
button displays the way you want to sort the records.
field, repeat steps 12 to 14 in this area.
Ascending–Sorts A to Z, 1 to 9 Descending–Sorts Z to A, 9 to 1
249
CREATE A REPORT USING THE REPORT WIZARD
+
You can perform calculations to summarize the data in your report.
Avg Calculate the average value.
Sum Add the values.
Sum
Avg
Min Min
Max
Min Find the smallest value.
Max Find the largest value.
CREATE A REPORT USING THE REPORT WIZARD (CONTINUED)
Order Date
Tribute Electronics : ...
¢ To perform calculations in your report, click Summary Options.
12:00 PM
Note: If you chose not to group data in your report, Summary Options will not be available. If Summary Options is not available, skip to step 21. The Summary Options dialog box appears.
250
12:00 PM
Tribute Electronics : ...
This area displays the fields you can perform calculations on.
∞ Click the box ( for each calculation you want to perform ( changes to ).
)
§ Click an option to specify if you want the report to display all the records and the summary information or just the summary ( changes to ). For more information, see the top of page 251.
Create Reports
Tip
11
When performing calculations in my report, what information can I display?
Month
Product
Units
Month
Product
Units
Month Feb
Feb
Tent
50
Compass
25
Fishing Rod
40
Paddle
20
Sleeping Bag
75
Sunglasses
45
Feb Mar Apr May
Sum
255
Sum
255
Sum
50
Sum
150
Sum
225
Units
Sum
255
% of Total Orders
15%
Mar
Apr
Product
Sum
50
% of Total Orders
3%
Sum
150
% of Total Orders
9%
Detail and Summary
Summary Only
Calculate percent of total for sums
Display all the records and the summary information. For example, show all the orders and the total orders for each month.
Display only the summary information. For example, show only the total orders for each month.
Display the percentage of the total that each group represents. For example, show the percentage of the total orders that each month represents.
Tribute Electronics : ...
¶ To calculate the percentage of the total that each group represents, click this option ( changes to ).
12:00 PM
• Click OK to confirm your selections.
Tribute Electronics : ...
ª Click Next to continue.
12:00 PM
You can click Back at any time to return to a previous step and change your selections.
251
CREATE A REPORT USING THE REPORT WIZARD
You can choose from several layouts for your report. The layout you choose determines the arrangement of information in your report.
k loc
O
B
e
ed
p
ep
St
lin ut
CREATE A REPORT USING THE REPORT WIZARD (CONTINUED)
Corporate
12:00 PM
Tribute Electronics : ...
º Click the layout you want to use for your report ( changes to Note: The available layouts depend on the options you selected for your report.
252
).
This area displays a sample of the layout you selected.
25 Click the style you want to use for your report.
– Click the page orientation you want to use for your report ( changes to ).
This area displays a sample of the style you selected.
≠ Click Next to continue.
12:00 PM
Tribute Electronics : ...
26
Click Next to continue.
Create Reports
Tip
Which page orientation should I use for my report?
The portrait orientation is the standard orientation and prints data across the short side of a page. The landscape orientation prints data across the long side of a page and can be useful when a report contains many fields.
Tip
11
Do I need to create a new report each time I change the data in my database?
No. Each time you open a report, Access will automatically gather the most current data from your database to create the report. This ensures that the report will always display the most up-to-date information. Access will also update the date displayed in the report. To open a report, see page 256.
Report ID Company Name
Con
1 US Sporting Goo
Gerry
2
Jessi
Sports Supplies Inc.
Customers Table3 Sports and Recreation Laura 4 ABC Sporting Goods JackC Company Name Contact First N
ID
5
Portrait
Landscape
Sports Plus
Lonn
1 US Sporting Goo
Gerry
2 Sports Supplies Inc.
Jessica
S
Tribute Electronics : ...
27 Type a name for your report.
12:00 PM
28 Click Finish to create your report.
Tribute Electronics : ...
A window appears, displaying your report. Note: To move through the pages in a report, see page 257.
Order Details
12:00 PM
29 When you finish reviewing your report, click to close the report.
253
CREATE A REPORT USING AN AUTOREPORT ORT
REP ails
et er D
Ord
1 Ski
ld Wor
les 0 e erID gogg $42.0 Ord Nam ski 100 pany Com t Name uc Prod 2 Price . Unit ity ue Inc nt Leag Qua Big nd 0 ID sta e er $50.0 Ord Nam T-ball 50 pany Com t Name uc Prod 3 ice Pr Unit ity ly nt Supp ua ty Q ck Varsi 0 e sti erID me ross $75.0 Ord Na lac 70 pany Com t Name uc Prod 4 Price Unit ity nt orld Qua
You can use the AutoReport Wizard to quickly create a report that displays the information from one table in your database.
Ski
W
d
.00 boar e erID $360 snow Ord Nam 30 pany Com t Name uc Prod 5 Price Unit ity ts Spor nt ium Qua Stad tball 0 foo ID r e er $45.0 Ord Nam leathe 90 pany Com t Name uc Prod Price Unit ity nt ua 02 Q 2, 20 day, Satur
Page
1 of
2
h Marc
e
ric 0 2.0 $4 0.00 0 $5 5.0 0 $7 0.0 0 6 0 $3 45. 00 $ 0. 0 $4 0.0 0 6 $3 40.0 0 $ 0.0 0 $4 0.0 9 $2
it P
Un
Comp Ski W any Name orl Big Le d ague Varsity Inc. Sup Ski Wor ply ld Stadium S Risky ports Whe Surfers elz A Indoor pparel Spo Spoke rts s 'n' Waver Stuff iders In c
A report summarizes the data from your database in a professional-looking document. CREATE A REPORT USING AN AUTOREPORT
Create report in Design view
AutoReport: Columnar
Order Details
12:00 PM
Tribute Electronics : ...
Tribute Electronics : ...
12:00 PM
⁄ Click Reports in
¤ Click New.
‹ Click the type of
ˇ Click the table that
the Database window.
The New Report dialog box appears.
AutoReport you want to create.
contains the data.
› Click
in this area to select the table that contains the data you want to include in your report.
254
Á Click OK to create your report.
Create Reports
Tip
What types of AutoReports can I create? Columnar AutoReport
Displays the field names down the left side of each page.
Displays the field names across the top of each page.
Big League Inc. T-ball stand $50.00 50 3 Varsity Supply lacrosse stick $75.00 70 4 Ski World snowboard $360.00 30
OrderID Company Name
Product Name
Unit Price Quantity
1 Ski World
ski goggles
2 Big League Inc.
T-ball stand
3 Varsity Supply
lacrosse stick
4 Ski World
snowboard
5 Stadium Sports
leather football
$45.00
6 Risky Wheelz
bike repair kit
$40.00
50
7 Surfers Apparel
dry suit
$360.00
30
8 Indoor Sports
volleyball
$40.00
60
9 Spokes 'n' Stuff
bike repair kit surfboard
Saturday, March 2, 2002
A window appears, displaying your report.
Page 1 of 2
Order Details
10 Waveriders Inc.
Tribute Electronics : ...
If you want to make changes to the data displayed in a report, you must change the data in the table you used to create the report. Changes you make to data in the table will automatically appear in the report the next time you open the report.
1 Ski World ski goggles $42.00 100 2
Saturday, March 2, 2002
Tabular AutoReport
Can I change the data displayed in a report?
Tip
Order Details OrderID Company Name Product Name Unit Price Quantity OrderID Company Name Product Name Unit Price Quantity OrderID Company Name Product Name Unit Price Quantity OrderID Company Name Product Name Unit Price Quantity
11
Order Details
Note: To move through the pages in a report, see page 257.
$42.00
100
$50.00
50
$75.00
70
$360.00
30 90
$40.00
90
$290.00
35 Page 1 of 1
12:00 PM
Tribute Electronics : ...
‡ To save your report, click File.
° Click Save. The Save As dialog box appears.
Order Details
12:00 PM
· Type a name for your report and then press the Enter key. ‚ When you finish reviewing your report, click to close the report.
255
OPEN A REPORT
You can open a report to display the contents of the report on your screen. Opening a report allows you to review and make changes to the report.
Company Name
Products
Quantity Unit Price
B&T Food Suppliers
S FORM RIES QUE
ES
L TAB
Kitty-Mart
Dry Cat Food
35
$4.00
REPORTS COLOR VIEW
Each time you open a report, Access uses the most current data from your database to create the report. OPEN A REPORT
Customer Information
12:00 PM
Tribute Electronics : ...
⁄ Click Reports in the Database window.
This area displays a list of the reports in your database.
The report appears. You can now review and make changes to the report.
¤ Double-click the
When you finish reviewing the report, click to close the report.
report you want to open.
256
Tribute Electronics : ...
Customer Information
12:00 PM
Note: A dialog box will appear if you did not save changes you made to the design of the report. Click Yes or No to specify if you want to save the changes.
MOVE THROUGH PAGES
If your report contains more than one page, you can move through the pages to review all the information in the report.
Order Details Details Order Details Order OrderID Company
OrderID Company Name OrderID Company World Ski 1
Create Reports
Product Product ProductskiName goggles
ski goggles World Ski 1 Ski Goggles 11 Ski World T-ball stand 2 Big League Inc. World 2 Big League Inc. Ski 1 T-ball stand T-ball Stand 12 Big League Inc. lacrosse stick 3 Varsity Supply stand T-ball Inc. 2 Big 3League lacrosse stick Varsity Supply Lacrosse Stick 3 Varsity Supply snowboard Ski 4World lacrosse stick Supply 3 Varsity snowboard Ski 4World snowboard Ski 4World leather football Stadium Sports 5 snowboard 4 Ski 5 World leather football Stadium Sports leather football 5 Stadium Sports bike repair kit Risky Wheelz 6 leather football Sports 5 Stadium bike repair kit Wheelz 6 Risky bike repair kit 6 Risky Wheelz dry suit 7 Surfers Apparel bike repair kit 6 Risky dry suit Surfers Apparel 7 Wheelz dry suit 7 Surfers Apparel volleyball Indoor Sports 8 dry suit Apparel 7 Surfers' volleyball Sports 8 Indoor volleyball 8 Indoor Sports bike repair kit Spokes 'n' Stuff 9 volleyball Sports 8 Indoor bike repair kit 'n' Stuff 9 Spokes bike repair kit 9 Spokes 'n' Stuff surfboard Inc. 10'n'Waveriders bike repair kit Stuff 9 Spokes surfboard 10 Waveriders Inc. surfboard 10 Waveriders Inc. surfboard 10 Waveriders Inc.
Unit Price Unit Price Unit Price$42.00
Quantity Quantity Quantity 100
$42.00 $42.00 $50.00 $42.00$50.00 $50.00 $75.00 $50.00$75.00 $75.00 $360.00 $75.00 $360.00 $360.00 $45.00 $360.00 $45.00 $45.00 $40.00 $45.00 $40.00 $40.00 $360.00 $40.00 $360.00 $360.00 $40.00 $360.00 $40.00 $40.00 $40.00 $40.00 $40.00 $40.00 $290.00 $40.00 $290.00 $290.00 $290.00
100 100 100 50 50 50 70 70 70 30 30 30 90 90 90 50 50 50 30 30 30 60 60 60 90 90 90 35 35 35
11
50 70 30 90 50 30 60 90 35
Page 1 of 1 Page 1 of 1 Page 1 of 1 Page 1 of 4
Thursday, May 22, 1997 Thursday, May 22, 1997 Thursday, May 22, 1997 Saturday, March 2, 2004
MOVE THROUGH PAGES
Tribute Electronics : ...
This area displays the number of the page displayed on your screen.
⁄ If your report contains more than one page, click one of the following buttons to display another page.
12:00 PM
Order Details
Tribute Electronics : ...
Order Details
12:00 PM
First page
MOVE TO A SPECIFIC PAGE
¤ Type the number of
Previous page
⁄ To quickly move to a
Next page
specific page in your report, double-click the current page number. The page number is highlighted.
the page you want to display and then press the Enter key.
Last page Note: If a button is dimmed, you cannot currently display that page.
257
CHANGE THE VIEW OF A REPORT
You can view a report in three different ways. Each view allows you to perform different tasks.
Design View
✓
w Print Previe View view Layout Pre View
CHANGE THE VIEW OF A REPORT
Tribute Electronics: ...
In this example, the report appears in the Print Preview view.
⁄ Click
in this area to display the report in another view. Note: The available views depend on the view you are currently using.
258
12:00 PM
Order Details
¤ Click the view you want to use. Note: If the view you want to use does not appear on the menu, position the mouse Œ over the bottom of the menu to display all the views.
Tribute Electronics: ...
The report appears in the view you selected. In this example, the View button changed from to .
Order Details: Report
12:00 PM
To quickly switch between the Print Preview ( ) and Design ( ) views, click the View button.
Create Reports
11
THE REPORT VIEWS
Design View
The Design view allows you to change the layout and design of a report. This view displays a grid of small, evenly spaced dots to help you line up the items in a report. Information in this view appears in several sections, such as the Report Header and Page Footer sections. cm
1
1 2 3
2
4 5
3
6 7 8
4
9 10
11
5
12 13
6
14 15
16 17
7 18
8
19 20
21 22
9 23
10
24 25
11
26 27
28
12
29 30
Print Preview View
The Print Preview view allows you to see how a report will look when printed. You can use this view to move through the pages in a report and examine how each page will print.
Layout Preview View
The Layout Preview view allows you to quickly view the layout and style of a report. This view is similar to the Print Preview view, but allows you to see only a few records in a report.
259
ZOOM IN OR OUT
Order Details When viewing a report, you can magnify an area of a page to view the area in more detail. You can also display an entire page in a report to view the overall appearance of the page.
Product Name
OrderID Company Name
Unit Price
Quantity
1 Ski World
Ski Goggles
$42.00
100
2 Big League Inc.
T-ball Stand
$50.00
50
3 Varsity Supply
Lacrosse Stick
$75.00
70
$360.00
30
4 Ski World
Snowboard
5 Stadium Sports
Leather Football
6 Risky Wheelz
Bike Repair Kit
$40.00 $45.00
90
$40.00
50
7 Surfers' Apparel
Wet Suit
$360.00
30
8 Indoor Sports
Volleyball
$40.00
60
Bike Repair kit
$40.00
90
$290.00
35
9 Spokes 'n' Stuff 10 Waveriders Inc.
Surfboard
$290.00
Page 1 of 1
Saturday, March 6, 2004
ZOOM IN OR OUT
Tribute Electronics : ...
⁄ To magnify an area of a page in your report, position the mouse over the area you want to magnify ( changes to ).
260
Order Details
12:00 PM
¤ Click the area to magnify the area.
Tribute Electronics : ...
The area appears magnified. To once again display the entire page, click anywhere on the page.
Order Details
12:00 PM
To display two pages in your report at a time, click . Note: To once again display only one page in your report at a time, click .
APPLY AN AUTOFORMAT
Create Reports
11
You can apply an autoformat to a report to quickly change the overall appearance of the report.
You may want to use the same autoformat for every report in your database to give your reports a consistent appearance.
04 29, 20 nuary day, Ja Thurs
, ary 29 Janu day, Thurs
2004
04 9, 20 ary 2 Janu day, Thurs
APPLY AN AUTOFORMAT
Bold
Tribute Electronics : ...
Customer Informatio...
⁄ Display the report you
‹ Click
want to change in the Design view. To change the view of a report, see page 258.
The AutoFormat dialog box appears.
12:00 PM
to select an autoformat for the report.
Tribute Electronics : ...
Customer Informatio...
12:00 PM
› Click the autoformat you want to use.
ˇ Click OK to confirm your change.
This area displays a sample of the autoformat you selected.
The report will display the new autoformat.
¤ Click
to select the entire report ( changes to ).
261
ADD A PICTURE
You can add a picture to a report to enhance the appearance of the report.
You can use a drawing program to create your own picture or use a scanner to scan an existing picture into your computer. You can also buy pictures at stores that sell computer software or obtain pictures on the Internet.
You can add a picture to a report, such as a picture of your products or your company logo. ADD A PICTURE
Tribute Electronics : ...
⁄ Display the report you want to add a picture to in the Design view. To change the view of a report, see page 258.
262
Products : Report
12:00 PM
¤ Click
on the Toolbox toolbar to add a picture to your report. If the Toolbox toolbar is not displayed, click to display the toolbar.
Tribute Electronics : ...
‹ Click the location in your report where you want the top left corner of the picture to appear.
Products : Report
12:00 PM
The Insert Picture dialog box appears.
Create Reports
Tip
What section of a report can I add a picture to?
Tip
You can add a picture to any section of a report. In most cases, you will want to add a picture to the Report Header section, which will display the picture at the top of the report.
Products
11
How can I delete a picture I added to a report?
To delete a picture you no longer want to appear in a report, click the picture and then press the Delete key. Access will remove the picture from the report, but will not remove the original picture from your computer.
Report Header
Product ID Product Name
Category
Page Header
Unit Price Units In Stock
1 Television
Video
$799.00
125
2 DVD Player
Video
$299.99
150
3 VCR
Video
$139.99
4 Speakers
Home Audio
$225.00
55
5 Cellular Phone
Communications
$149.99
100
6 CD Changer
Home Audio
$525.00
75
7 Flat-Screen Television
Video
$1,299.99
200
8 Digital Camera
Photography
$699.99
45
80
Detail
Delete Wednesday, January 30, 2002
Page Footer
Page 1 of 1
Group of Products
Tribute Electronics : ...
This area shows the location of the displayed pictures. You can click this area to change the location.
Products : Report
Tribute Electronics : ...
12:00 PM
› Click the name of the picture you want to add to your report.
ˇ Click OK to add the picture to your report.
The picture appears in your report.
Á Click
to save the change you made to your report.
Products : Report
12:00 PM
Note: You can move or resize a picture in a report as you would move or resize a control on a form. To move or resize a control on a form, see page 154.
263
s Jack Adam Ave. 258 LintonNY 10010 , rk Yo New
Erin Baker r Ave. 68 Cracke co, CA 94110 San Francis
Carl Davis Cres. 26 Arnold , FL 32256 Jacksonville
Lisa Bell St. 10 Heldon A 30375 Atlanta, G
n Julie Brow . 15 Bizzo PlNY 10020 , rk New Yo er Alan Cart Ave. 18 Goulage , CA 90032 les ge An Los
Jack Adams e. 258 Linton Av 10010 New York, NY Matt Cole ne 50 Tree LaA 02117 Boston, M Jason CookAve. 47 Crosley NV 89116 Las Vegas, s Simon Evan. 401 Idon Dr 37243 TN , Nashville er Paul Fras d St. 36 BuzzarA 02118 M , Boston Sue Grante St. 890 Appl CA 92121 San Diego, ris Linda Hare. 11 Lent Av A 30367 G a, nt la At
s Jack Adam Ave. 258 Linton NY 10010 New York, r Erin Bake ve. rA 68 Cracke , CA 94110 co cis an Fr n Sa Carl Davis es. Cr 26 Arnold FL 32256 e, Jacksonvill Lisa Bell St. 10 Heldon 30375 A Atlanta, G n Julie Brow . 15 Bizzo Pl Y 10020 N New York, r Alan Carte Ave. e 18 Goulag CA 90032 s, ele Los Ang
SHIP
Matt Cole ne 50 Tree La 02117 A Boston, M Jason Cook ve. A 47 Crosley V 89116 ,N Las Vegas ans Simon Ev r. 401 Idon D 37243 TN Nashville, Paul Fraser . d St 36 Buzzar 02118 A Boston, M Sue Grant . St 890 Apple CA 92121 San Diego,
Erin Baker e. 68 Cracker AvCA 94110 San Francisco, Carl Davis es. 26 Arnold CrFL 32256 Jacksonville, Lisa Bell 10 Heldon St.30375 Atlanta, GA Julie Brown 15 Bizzo Pl. 10020 New York, NY Alan Carter e. 18 Goulage Av 90032 Los Angeles, CA
Matt Cole 50 Tree Lane 117 Boston, MA 02 Chuck Deanee. 47 Crosley Av 89116 Las Vegas, NV Susan Hughes 401 Idon Dr. 37243 Nashville, TN y Greg Kilkenn 36 Buzzard St.118 02 Recipe ID Boston, MA Jim Martin . 890 Apple St 92121 San Diego, CA
Recipe Name
Meal
1 Chicken Stir-fry Dinner
Ron Ratoff 11 Lent Ave.30368 Atlanta, GA
ris Linda Har . ve 11 Lent A 30368 A G a, Atlant
Vegetarian No
2 Omelet
Breakfast
Yes
3 Veggie Pizza
Lunch
Yes
4 Lasagna
Dinner
5 Pancakes
Breakfast
6 Pork Chops
Dinner
No
7 Garden Salad
Lunch
Yes
8
Breakfast
Yes
Fruit Salad
No Yes
250mL 150mL 50mL
TO:
P & T Fruit Marke t 892 Apple St. San Diego, CA 92121
AD3 PUSH
ickeh Pry TCrhry C Cur
CHAPTER 12
Print Information Are you ready to print the information in your database? In this chapter, you will learn how to preview your data before printing, change the way the data will appear on a printed page and create mailing labels. Preview Before Printing ....................266 Change Page Setup ........................268
en keny kCehnick hicC ryCurhric ❧ ❧❧ ❧❧ ❧ ❧❧ ❧❧
Print Information ..............................270 ❧❧❧❧❧ ❧❧❧❧❧
Create Mailing Labels......................272
PREVIEW BEFORE PRINTING
You can use the Print Preview feature to see how a table, query, form or report will look when printed.
Recipe ID
Recipe Name
Meal
1 Chicken Stir-fry Dinner
Vegetarian No
2 Omelet
Breakfast
Yes
3 Veggie Pizza
Lunch
Yes
4 Lasagna
Dinner
5 Pancakes
Breakfast
6 Pork Chops
Dinner
No
7 Garden Salad
Lunch
Yes
8 Fruit Salad
Breakfast
Yes
No Yes
250mL 150mL 50mL
n
e hick ickehrnic y kCen Pry TCrrhy C Cur
AD3 PUSH
❧ ❧❧ ❧❧ ❧ ❧❧ ❧❧
The Print Preview feature can help you confirm that your printed pages will appear the way you want.
❧❧❧❧❧ ❧❧❧❧❧
PREVIEW BEFORE PRINTING
Employees
12:00 PM
Tribute Electronics : ...
⁄ In the Database window, click the type of object you want to preview. ¤ Click the object you want to preview.
266
‹ Click
to preview
the object. A window appears, displaying how the object will look when printed.
Tribute Electronics : ...
This area shows the number of the page displayed on your screen.
› If the object contains more than one page, click one of the following buttons to display another page.
12:00 PM
Employees : Table
First page Previous page Next page Last page Note: If a button is dimmed, you cannot currently display that page.
Print Information
Tip
How can I display two pages at once while previewing an object?
To display two pages at once, click the Two Pages button ( ). To once again display only one page at a time, click the One Page button ( ).
Tip
Can I see how an object will print in different views?
Yes. To see how an object will print in a specific view, display the object in the view of interest and then click the Print Preview button ( ). For example, you can display a table in the Datasheet, PivotTable or PivotChart view. To change the view of an object, see pages 74, 152, 202 and 258.
Datasheet
PivotTable
Sale Marketing Human Resources Sales Sales Human Resources Marketing Sales Marketing Accounting Sales Sales Production Production Marketing
Tribute Electronics : ...
Employees : Table
12:00 PM
MAGNIFY AN AREA OF A PAGE
¤ Click the area to
⁄ To magnify an area of a
magnify the area.
page, position the mouse over the area you want to magnify ( changes to ).
12
Tribute Electronics : ...
Jack Erin Lisa Julie Alan Matt Jason Carl Simon Paul Sue Linda Frank David Nancy
Employees : Table
PivotChart
Adams Baker Bell Brown Carter Cole Cook Davis Evans Fraser Grant Harris Hill Jones King
12:00 PM
A magnified view of the area appears.
CLOSE PRINT PREVIEW
To once again display the entire page, click anywhere on the page.
previewing the object, click Close to close the preview window.
⁄ When you finish
267
CHANGE PAGE SETUP
You can change the way information appears on a printed page.
Access stores the page setup options you specify for forms and reports so you need to specify the options only once for each form or report. For tables and queries, you must specify the page setup options every time you want to print a table or query. CHANGE PAGE SETUP
Customers
Tribute Electronics : ...
⁄ In the Database window, click the type of object you want to use different page setup options.
268
12:00 PM
Tribute Electronics : ...
¤ Double-click the object
The object opens and appears on your screen.
you want to use different page setup options.
‹ Click File.
Customers : Table
12:00 PM
› Click Page Setup. The Page Setup dialog box appears.
Print Information
Tip
12
What page setup options can I change? Orders Customers
5/16/2002
Page 1
Margins
Print Headings
Print Data Only
Orientation
Paper Size and Source
Determines the amount of space between data and the edges of each page.
Prints headings, which include the title, date and page numbers. This option is only available for tables and queries.
Prints only the data. This option is only available for forms and reports.
Determines which direction information prints on each page.
Specifies the paper size and the location of the paper that you want to use in the printer.
Tribute Electronics : ...
This area displays the margins for each page.
ˇ To change a margin, double-click the box beside the margin and then type a new margin.
Customers : Table
12:00 PM
Á If you do not want to print the title, date and page numbers, click Print Headings ( changes to ). Note: For forms and reports, the Print Data Only option appears instead. To print only the data in the form or report, click the option ( changes to ).
Tribute Electronics : ...
Customers : Table
12:00 PM
‡ Click the Page tab. ° Click the page
‚ Click OK to confirm your changes.
orientation you want to use ( changes to ).
Note: You can use the Print Preview feature to see how the printed pages will appear. To use the Print Preview feature, see page 266.
· These areas display the paper size and source. You can click an area to change the paper size or source.
269
PRINT INFORMATION
You can produce a paper copy of a table, query, form or report.
4
4/5/200
uery State Q
Last Nam Adams
e
First Nam Erin
eles Los Ang
Alan
Car ter
Davis
Evans
CA
CA
CA
ield
Bakersf
Jason
Cook
CA
Anaheim
Matt
Cole
Before printing, make sure your printer is turned on and contains paper.
CA cisco
San Fran
Julie
Brown
CA
San Jose
Lisa
Bell
When you print a table, query or report, Access prints the title, date and page number on each page.
CA
Anaheim eles Los Ang
Jack
Baker
State
City
e
o
rancisc San F
s Spring Palm
Carl
Simon
Long B
Paul
each
CA
CA CA
Fraser
1 Page
PRINT INFORMATION
Order Details
12:00 PM
Tribute Electronics : ...
⁄ In the Database window, click the type of object you want to print.
¤ Double-click the object you want to print. The object opens and appears on your screen.
Tribute Electronics : ...
If you want to print only one record or a few records, select the record(s) you want to print. To select records, see page 54.
‹ Click File. 270
Order Details : Table
12:00 PM
› Click Print. The Print dialog box appears.
Print Information
Tip
What print options can I use?
12
Can I print an object in a different view?
Tip
Yes. Before you print an object, make sure you display the object in the view you want to print the object. For example, you can display a table in the Datasheet, PivotTable or PivotChart view. To change the view of an object, see pages 74, 152, 202 and 258.
All
Prints every page. Page 1
Pages
Prints the pages you specify. Page 1
Selected Record(s)
Prints the record(s) you selected.
960001 June 960002 Frank
Burke Dawson
(201) 555-4591 (201) 555-1479
Datasheet
PivotTable
PivotChart
HP LaserJet 5MP
1 LPT1:
Tribute Electronics : ...
ˇ Click the print option you want to use ( changes to ). Note: For information on the print options, see the top of this page.
Order Details : Table
Tribute Electronics : ...
12:00 PM
If you selected Pages in step 5, type the number of the first page you want to print. Press the Tab key and then type the number of the last page you want to print.
Order Details : Table
12:00 PM
QUICKLY PRINT ALL RECORDS
⁄ Click
to quickly print all the records.
Á Click OK. 271
CREATE MAILING LABELS
You can create a mailing label for every person in a table. You can use mailing labels for addressing envelopes and packages, labeling file folders and creating name tags.
SHIP TO
:
P & T Fruit Market 892 Apple St. San Diego, CA 92121
The Label Wizard asks you a series of questions and then creates mailing labels based on your answers. CREATE MAILING LABELS
Create report in Design view
Label Wizard Customers
12:00 PM
Tribute Electronics : ...
Tribute Electronics : ...
⁄ Click Reports in
¤ Click New.
‹ Click Label Wizard
the Database window.
The New Report dialog box appears.
to use a wizard to create mailing labels.
› Click
in this area to select the table that contains the information you want to appear on the labels.
272
12:00 PM
ˇ Click the table that contains the information. Á Click OK to continue.
Print Information
Tip
12
What information must I specify when creating mailing labels?
When creating mailing labels, you must specify the manufacturer, type and size of labels you want to use. Sheet feed
Labels
Labels
Avery
Continuous 1 3" 3 /
Labels
CoStar
2" x
Herma
x4
4"
"
4" 1 1/3" x 1" x 2
5 /8"
Manufacturer
Label Type
Label Size
You can select from several different label manufacturers, such as Avery, CoStar and Herma.
You can choose between sheet feed and continuous labels. Sheet feed labels are individual pages of labels. Continuous labels are connected pages of labels, usually with holes punched along each side.
You can select a label size to specify the dimensions of each label and the number of labels that will print across each page.
C2160
1 1/2" x 2 1/2"
3 3612
2" x 3 1/2"
2
Avery Avery
Tribute Electronics : ...
The Label Wizard appears. This area displays the available label sizes for the current manufacturer.
12:00 PM
‡ To display the label sizes for a different manufacturer, click in this area. ° Click the manufacturer of the labels you want to use.
Tribute Electronics : ...
· To change the unit of measure or type of label displayed, click the appropriate options ( changes to ).
12:00 PM
Note: You can check your label packaging to determine which label size to select.
— Click Next to continue.
‚ Click the label size you want to use.
273
CREATE MAILING LABELS Jack Adams 50 Tree Lane02117 Boston, MA
Jason Cook . 258 Linton Ave 10010 New York, NY
You can change how text will appear on your mailing labels.
Carl Davis . 68 Cracker Ave , CA 94110 San Francisco
Erin Baker . 47 Crosley Ave 89116 Las Vegas, NV
Jason Cook 258 Linton Ave. New York, NY 10010
Jack Adams 50 Tree Lane Boston, MA 02117
Lisa Bell 401 Idon Dr. 37243 Nashville, TN
Carl Davis 68 Cracker Ave. San Francisco, CA 94110
Erin Baker 47 Crosley Ave. Las Vegas, NV 89116
Julie Brown St. 36 Buzzard 02118 Boston, MA
Simon Evans 26 Arnold Cres. Jacksonville, FL 32256
Lisa Bell 401 Idon Dr. Nashville, TN 37243
Paul Fraser 10 Heldon St. Atlanta, GA 30375
Julie Brown 36 Buzzard St. Boston, MA 02118
Simon Evans s. 26 Arnold CreFL 32256 Jacksonville, Paul Fraser . 10 Heldon St30375 Atlanta, GA Sue Grant 15 Bizzo Pl. 10020 New York, NY Linda Harris . 18 Goulage Ave CA 90032 Los Angeles,
Alan Carter . 890 Apple St92121 San Diego, CA
Matt Cole Sue Grant 11 Lent Ave. 30367 15 Bizzo Pl. Atlanta, GA New York, NY 10020 Linda Harris 18 Goulage Ave. Los Angeles, CA 90032
Alan Carter 890 Apple St. San Diego, CA 92121
Jason Cook 258 Linton Ave. New York, NY 10010
Jack Adams 50 Tree Lane Boston, MA 02117
Carl Davis 68 Cracker Ave. San Francisco, CA 94110
Erin Baker 47 Crosley Ave. Las Vegas, NV 89116
Simon Evans 26 Arnold Cres. Jacksonville, FL 32256
Lisa Bell 401 Idon Dr. Nashville, TN 37243
Paul Fraser 10 Heldon St. Atlanta, GA 30375
Julie Brown 36 Buzzard St. Boston, MA 02118
Sue Grant 15 Bizzo Pl. New York, NY 10020
Alan Carter 890 Apple St. San Diego, CA 92121
Linda Harris 18 Goulage Ave. Los Angeles, CA 90032
Matt Cole 11 Lent Ave. Atlanta, GA 30368
Matt Cole 11 Lent Ave. Atlanta, GA 30368
The changes you make to the appearance of text on your mailing labels will affect all the text on every label. You cannot change the appearance of text for part of a label or only some labels.
CREATE MAILING LABELS (CONTINUED)
8
Arial
10
Tribute Electronics : ...
This area displays how the text on your labels will appear.
12:00 PM
This area displays options you can use to change the appearance of the text on your labels.
Tribute Electronics : ...
± To change the font, size or weight of the text on your labels, click below the name of the option you want to change. ¡ Click the option you want to use.
274
12:00 PM
™ To italicize or underline the text on your labels, click the appropriate option ( changes to ).
£ Click Next to continue.
Print Information
Tip
How can I select a different text color for my mailing labels?
Tip
In the Label Wizard, click the button ( ) beside the Text color box. In the dialog box that appears, click the color you want to use for the text and then press the Enter key. You need a color printer to be able to print the text on your mailing labels in color.
12
Can I display the same text on every mailing label?
Yes. You can display text, such as "Confidential" or "Important", on every mailing label. After you add the fields you want to display on the mailing labels in the Label Wizard, type the text you want to appear on every mailing label in the Prototype label area.
k 7 Coo ne 211 on La A 0 Jas 0 Treeton, M ntial 5 os fide 6 B on ve. 911 s C avi y A V 8 rl D roslegas, Nial ms Ave. 10010 a a C C d t 47 as Vefiden k A ton NY L on Jac 90 LinYork, ntial ns 43 C 2 ew fide Eva r. 372 N on on n D TN e . 9 4110 r v C e A Sim01 Idohville, ntial ak ker o, CA B e 4 c c Nas onfid l Erin8 CraFrancis ntial C 6 an fide ntia S on fide ith es. 256 C Conim Sm Linto ell ld Cr , FL 32 B J o le a 290 ew Yo Lis 6 Arnsonvil ntial N 2 ack fide J n l 0
BillingAddress Zip Code
Tribute Electronics : ...
This area displays the fields from the table you selected in step 5.
¢ Double-click a field you want to appear on the labels.
12:00 PM
The field you select appears in this area.
∞ To add a blank space, press the Spacebar. To move to the next line, press the Enter key.
Tribute Electronics : ...
§ Repeat steps 16 and 17 until this area displays all the fields you want the labels to display. Note: The fields should appear the same way you want them to print on your labels. Make sure you add spaces and commas (,) where needed.
12:00 PM
To remove a field you accidentally selected, click the field in this area and then press the Delete key.
¶ Click Next to continue.
275
CREATE MAILING LABELS
You can sort your mailing labels to better organize the labels.
Jack Adams 258 Linton Ave. Anaheim, CA 92803
Kevin Turner 10 Heldon St. Beverly Hills, CA 90210
Erin Baker 12 Downing Ave. Long Beach, CA 90809
Simon Evans 215 Royal Dr. Los Angeles, CA 90052
Lisa Bell 26 Arnold Cres. San Diego, CA 92199
Frank Hill 15 Main St. San Jose, CA 95101
Julie Brown 47 Crosley Ave. Buffalo, NY 14240
Nancy King 142 King St. New York, NY 10199
Alan Carter 168 Cracker Ave. Syracuse, NY 13220
Stacy Lee 50 Tree Lane Utica, NY 13504
For example, you can sort your mailing labels by state to place all the labels for the same state together. If the same state appears on several labels, you can sort your labels by a second field, such as city, to further organize the labels.
CREATE MAILING LABELS (CONTINUED)
State
Fax Number
State
Tribute Electronics : ...
• To sort your labels, double-click the field you want to use to sort the labels.
276
12:00 PM
Note: If you do not want to sort your labels, skip to step 21.
Tribute Electronics : ...
The field you selected appears in this area. To remove a field you accidentally selected, double-click the field in this area.
12:00 PM
To sort the labels by a second field, double-click the field in this area.
ª Click Next to continue.
Print Information
Tip
How do I print the mailing labels I created?
When viewing your mailing labels, click the Print button ( ) to print all the labels. Before printing your mailing labels, make sure your printer is turned on and the labels are in the printer. For more information on printing, see page 270.
Tip
How do I edit the mailing labels I created?
To edit mailing labels, you must change the data in the table you used to create the labels. Changes you make to the data in the table will automatically appear in the labels the next time you open the report containing the labels. me world plies ation oods Plus
Off
Tribute Electronics : ...
º Type a name for your labels.
12
Billing Address 121 Queen St. West 609 Water St. 7078 Rogers Rd. 802 College St. 9 George St
City New Los Cew Sao New
On
12:00 PM
– Click Finish to create your labels. You can click Back to return to a previous step and change your selections.
New York, NY. 10199
Los An
Sport and Recreation Inc. 10 Headon St. Charlotte, NC 28228
Varsity 802 Co San Jos
ABC Sporting Goods 26 Arnold Cres
Sports Beverly
Tribute Electronics : ...
A window appears, displaying a personalized label for each person in your table.
≠ When you finish
Customer Labels : Re...
12:00 PM
Access stores your labels as a report. To later open a report so you can once again review and print your labels, see page 256.
reviewing the labels, click to close the window.
277
22040
COLOR VIEW
of 4 Customers 3
Customers 1 of 4
CHAPTER 13
Create Data Access Pages Are you wondering how you can use Access to share data with other people on the Internet? This chapter shows you how to create and work with data access pages for the Web. Create a Data Access Page..............280 Change the View of a Data Access Page ................................286 Open a Data Access Page ..............288 Add a Title ....................................289 Move Through Records ....................290 Apply a Theme ..............................292 Rename a Data Access Page ............294 Delete a Data Access Page ..............295
ode:
Zip C
CREATE A DATA ACCESS PAGE
You can use the Page Wizard to create a data access page, which is a Web page that connects directly to the data in your database.
You can use a data access page to view and edit the data in your database on the Internet or your company's intranet. An intranet is a small version of the Internet within a company. The Page Wizard will ask you a series of questions and then set up a data access page based on your answers.
CREATE A DATA ACCESS PAGE
Create data access page by using wizard Table: Customers
Tribute Electronics: ...
To create a data access page, you must have Internet Explorer 5.01 with Service Pack 2 (or a later version) installed on your computer.
⁄ Click Pages in the Database window.
280
12:00 PM
¤ Double-click Create data access page by using wizard.
Tribute Electronics: ...
The Page Wizard appears.
‹ To select the table that contains the fields you want to include in your page, click in this area.
12:00 PM
› Click the table that contains the fields.
Create Data Access Pages
Tip
Which tables in my database can I use to create a data access page?
13
Can I create a data access page using data from a query?
Tip
You can use any table in your database to create a data access page. When creating a data access page that uses information from more than one table, relationships must exist between the tables so that Access can bring together the information in the tables. For information on relationships, see page 128.
Yes. The Page Wizard allows you to select the fields you want to include from queries as you would select the fields you want to include from tables. For information on queries, see pages 192 to 229.
e taleCod PosCod e tal Code e incPos te/Pincrov 10 e10Postal Starov te/P Code 100 rovinc Postal y Sta te/P100 Code ince10 City Cit NY Sta 021te/P 17rov17100 Postal e s Sta 021 k CitNYy 100 ince10 tal Cod Adds res YorwkYor Addres 10021rov17 100 MAy NY 10 e Pos State/P Ne 941 resw. sNe MAk Cit . Ave 94110 rovinc t Name Ave tonAdd 02117 Name n w Yor y NY te/P t Las s Lin ton 10 Ne 10 Cit sto MA n Sta . Las res k Lin 258 Bo stoAve 17 100 Yor me NY 16941 t Name 891 etonAdd h 258 10021 nCAw CA sco Las 891 MA City16 . sNe LinBo NastmeNa nci eeLan sto res sco me Lan Ave 258 Bo Fra Tre FirstFir mit nci Schhmit York Add NY16941 teNa CA me ton w 02117 50 Fra ID Tre Sch 891 e San n 56 Na Las s s Lin Ne . NV h 50 ID sco MA . sto San Lan res k322 .eAve NVnci First me Bo Ave 1694110 322 Adds res rsonmit Yor56 Add CA Na Trer258 Sch tAve asFra r cke ttenme eton Addres Na rso 50 ID hCra Las as San sco Veg MA56891 Lan .nNew .Lin Jim1s Jim stoNV nci eme PeFirttestPe 94110 68cke Veg 1 res Cra Las nmit 43322 258 BoAve Ave 16 FL Fra Tre Na . r Sch 68 CA Add me rso t Las 43 372 ton FL 50 as 891 e ID . cke Na Ave tte San n 56 s Jim lle Lin h Las 372 .Veg sco NV Lan Cra Ave res1nda sby nvi botstPe n68 lle Fir mit Bre e258 Ave 16 2nda r Las sby Cro nvi Add CA43322 me Sch FLBoncisto sco75372 .kso 2 Bre ckeTre 47rso TalbotTal Cro Jac Na 50 ID SaneasFra 56 891 Ave sJim Pesttte Cra s.hkso .Veg lleTN NV Jac Fir47 res1nda mit 75 e Lan 303 TN sby nvi Cre s.n68 bot Ave 43322 r Las Franci Tre 2dBre Sch rso Cro old asFL303 d Add cke 50 ille.kso tte47Cre Jim Jac s IDanTal Arn De lle . San an NV75372 1nda Cra ille shvAve TN s. sby 32256 26Peold 3 Tod3 Tod 2dAdd Arn Deres nNa Bre AveVeg 68 shv Las Cre r nvi Talbot Cro kso FL 18303 . GA Narso as 18 021 37243 tteold 47 Jac an26 GA Jim Tod Ave illecke Dr. son
75 TN Veg nda 021 1De Cra s.shv 3 nArn bin Dr.Pe son Chuck nville 68 Bre 26 Ido asby Na d Ro FL18303 Talnbot .GALas antCre old aCro Ro2bin 4 Ch4uck 37243 401 ille 47Atl Jac Avekso ant 3 Tod De nda lle 20021 Dr. sonanIdo TN s. MA shv 20 100 nArn sby 26 bot bin401 Na St.Atl Cre 1830375 100nvi ie4lanChieuck Hu aMA Cro d2RosBre GA St.TalnIdo sghe 47 ann401 ldo Jackso ille noldant Dr.Atl son 3gheTod TN20021 He s.MA ldo sto 5 Me5lanMe Hu 26 30375 ie uck He10De BonArn Na sto aCreshv Ro 4 Ch St. ds bin GA 21100 BonIdo antNY 921 an St. ghe10 ille21 2002118 Atl ldo nNYold 3HusTod son Arn De rd401 5 Melan Ch MA 921 St. kDr. He pin iesuck Susan bin 26nsto rd10zza Yor kSt. sBu 18 aNashv Bo 4pin Top zza GA21100 YorwnIdo 6 Su6san Bu36Ro Toplan Ne ldo n antNY St. 5 Me 20 021 Atl son Hus ghe 36 CA uck MA32921 NeHe 900 rdw401 san kn Dr. bin ieCh y pin CAsto Bo zza Ido 900 a 32 St. 21100 Pl.10 4Top NY n Yor Bu enn wgo Pl. ghe 401 Meylan St. n 6nSu ldo 36zosRo nAtlant Ne 5enn Kilk zosBiz rdgoDie MA32921 He k CA sto pin 10020 15Hu 900 ieBiz Kilksan 7 Alle7 Alle 6n Su zza Die 67 10 San Yor Bo St. CA s y lan 21 Bu 15 Top NY n Pl. w 67 San 303 CA ghe Me enn 36 32921 zo Ne St. ldo go n es son Hu 303 sBizSt. rdHe san CA Die rcu5Kilk es ple pin g 7g Alle Ma6nrcu Suson zza 10gel 15St. y Ap Boksto gel Ma Yor Pl.An ple San NY67900 Top w CA An Ap zo LosBu 8 Gre8 Gre 7g Alle go 890 32 92121 NeSt. s.36 Biz Kilk esGA St. sonenn Die Los rd san 890 10 .pin CA 10303 k902 Ave 900 15 gel GA Surcu zza ple 67 Gre ge San y Yor Ave CA 902 6 on An Pl. Bu Ap Top Ma n 8 w ula enn zo 36 a Los Allertin Goge 890 son ula Ma Die ant.St. CA10303 GANego 39 aBiz 90032 18Kilk geles rcu 9 Jas9onJas 8onGre ple Ave Ma7grtin ant y15Atl San CA Ma CA 39902 Pl. n Go s 18 enn .AtlgeAp zo An Los go900 ula 890 1030367 .St. Alle 900 rtin lsaCA ew s7Ma es son Biz Go GA Kilk . 9 Jas Ave Die g Hil tth t ls Ave ew 902 ant gel rcu ple 15 18 Jim Ave Gre 39 Ma Hil tth Atl AnSan tLen CA erly 8 10 Maon ula 30367 s11Ma erly rtin Bev Los . geAp 890 10 Jim Go es 70900 son 70GA lsaSt. CA 019 gewLen Ma ant en9 Jas CA s.Ave 18 Ave rcu Hil.CA tth11 ple 3990210 tBev Atl es Angel019 enhleJim Cre s.Len ge Ap f Gre erly gel es Kat10 ula Cre .890 f tofon8Ma erly Jas 11 Ma gelAn ls.aLosCA Bev ew 11hle Go 9 Ra GA70900 Ovsrtin Ma 019 An Hil ttherly antCA ts.Ave Los Ra 11 Kat entof 39 90210 AtlAve ge esMA Los Len on Cre18 f Ov4 St. ula s11 St. gelerly rtin Kat10hleJim enltfau .MA Bev ltJas tof4Ma CAa CA Go An ew 01970900 Maerly Ov s.t Ave 18 39 n Ro11n 4llow emLos Witth es fau Jim 9Ra MAAtlHilantls llow Thy Cre gel em Wi13fMa 10hle sSalLen Thy . erly 11 12 Ro12 St. AnBev Sal 13 CAls CA Ralttof 11n Kat 01970 900 Ovewerly St. Los en fau s.t Ave llow MA Jim Ma Wi4tth hle erly Hil CA Len Cre futh 10Thy So 12nRo 11 geles Sal 13St. St. Katlfe 11em tof So 13nJoh Raltuth 01970 486 Overly WonlfeWo llow Loss. AnBev gelMA 13 Joh es Thyenfau hle l n Ro fWi4St. 12 SalemCre 13 lfe486 an Kat tofuth St. Joh lt So 11Wo St. 13l hae Mic 486Ra fau llow Bat 4 Overly Salem Los An MA Roannem 14hae Bat l12nem 14 Mic Joh St. anlfeThy ltSo13uthWi 13hae 486 emnWo fau St. llow Mic Ro lise Bat em Wi Thy n uth 14 l De 12 lise anlfe haeJoh emWo 486 So13 uth St. Sal 15 De15 liseMic13 haeJoh 14 n l Bat So an Wolfe 15 De em 13 486 Mic Bat lise an 15 De14 hael Batem lise Mic 15 De 14 lise 15 De
Query: Employees Query
LES TAB
Query: Employee Sales Query
CompanyName
Discount
Quantity
Tribute Electronics: ...
This area displays the fields from the table you selected.
12:00 PM
ˇ Double-click each field you want to include in your page. Note: To add all the fields in the table at once, click .
Tribute Electronics: ...
Each field you select appears in this area. To remove a field you accidentally selected, double-click the field in this area. Note: To remove all the fields at once, click .
12:00 PM
Á To include fields from other tables in your database, repeat steps 3 to 5 for each table.
‡ Click Next to continue.
281
CREATE A DATA ACCESS PAGE
You can group the data in your data access page to place related information together. Grouping data helps you organize the data in your page.
CompanyName CompanyName
Blue Nose Sports
FL
Customer ID CompanyName Customer ID
For example, you can group all the customers from the same state together in your data access page.
Athletics Inc.
CA
BillingAddress
14 Pine Street
City
Los Angeles
Postal Code
90012
BillingAddress 6049 City Postal Codes
33 Sunshine Ave. Fort Myers
Racquets & Stuff
NY
Customer ID BillingAddress 4672 City Postal Codes
7144
99 Blue Road New York 10055
33905
CREATE A DATA ACCESS PAGE (CONTINUED)
CompanyName Zip Code
Tribute Electronics: ...
12:00 PM
Tribute Electronics: ...
This area displays all the fields you selected to include in your page.
This area shows how Access will group the data in your page.
‚ To sort the records in your page, click in this area.
° If you want to group data in your page, double-click the field you want to use to group the data.
To remove a field you selected to group data in your page, double-click the field in this area.
Note: For information on sorting, see the top of page 283.
· Click Next to continue. 282
12:00 PM
— Click the field you want to use to sort the records.
Create Data Access Pages
Tip
13
Why would I sort the records in my data access page?
You can sort the records in your data access page to better organize the records. For example, you can sort records alphabetically by the Last Name field to make it easier to find customers of interest. If the same last name appears more than once in the field, you can sort records by a second field, such as First Name, to further organize the records. You can use up to four fields to sort the records in a data access page.
Last Name First Name
Williams Sue
Company Name Bike & Stuff
Last Name City First Name
Smith Key West Bob
State / Province FL Company Name Sports Stop
Smith Last CityName Austin Allison First Name State / Province TX Company Name Mind Games Last Name Abbott Fort Myers City First Name Jennifer State / Province FL Company Name City State / Province
Ski World New York NY
CompanyName Customers
Tribute Electronics: ...
12:00 PM
± Click this button until the button displays the way you want to sort the records.
¡ To sort by a second
Ascending–Sorts A to Z, 1 to 9
™ Click Next to
Descending–Sorts Z to A, 9 to 1
field, repeat steps 10 to 12 in this area. continue.
Tribute Electronics: ...
If you included fields from more than one table and you chose not to group data in step 8, this screen appears. Note: If the screen does not appear, skip to step 17.
12:00 PM
£ Click the table you want to be able to edit. Note: You will not be able to edit data in the other table(s).
¢ Click Next to continue.
283
CREATE A DATA ACCESS PAGE
When creating a data access page, you can give the page a descriptive title.
When you view a data access page, the title you specify will appear at the top of the window. CREATE A DATA ACCESS PAGE (CONTINUED)
Tribute Electronics: ...
12:00 PM
∞ Type a title for your page.
¶ Click Finish to create your page.
§ Click this option to open the page when you finish creating the page ( changes to ).
You can click Back to return to a previous step and change your selections.
284
Tribute Electronics: ...
Customer Orders
12:00 PM
The page appears, displaying the information for the first record.
Note: To move through records in a data access page, see page 290.
If the information for the record does not appear, click beside the first field on the data access page to display the information ( changes to ).
• Click your page.
to save
Create Data Access Pages
Tip
Where does Access store a data access page I create?
Tip
Access stores a data access page as a separate file outside of your database and displays a shortcut to the file in the Database window. To use the shortcut to open a data access page within Access, see page 288.
Tribute Electronics: ...
The Save As Data Access Page dialog box appears.
ª Type a file name for your page.
Customer Orders
How do I make my data access page available for other people to view?
To make a data access page available on the Internet or your company's intranet, you need to transfer the page to a Web server. A Web server is a computer that stores Web pages and makes the pages available for other people to view. For information on publishing a data access page to a Web server, contact your Web server administrator.
12:00 PM
This area shows the location where Access will store your page. You can click this area to change the location.
º Click Save to save your page.
13
Tribute Electronics: ...
Access saves the page. If you saved the page on your computer rather than on the Internet or your company's intranet, the Microsoft Office Access dialog box appears.
Customer Orders
12:00 PM
– Click OK to close the dialog box. ≠ When you finish reviewing the page, click to close the page.
285
CHANGE THE VIEW OF A DATA ACCESS PAGE
Page View
Design View
Web Page Preview
You can view a data access page in three different ways. Each view allows you to perform different tasks.
Select View
1
2
3
USING THE PAGE AND DESIGN VIEWS
Tribute Electronics: ...
In this example, the data access page appears in the Page view.
286
Customer Orders
⁄ Click
12:00 PM
to display the data access page in the Design view.
Tribute Electronics : ...
The data access page appears in the Design view.
Customer Orders : D...
12:00 PM
The View button changed from to To quickly switch between the Page ( ) and Design ( ) views, click the View button.
.
Create Data Access Pages
Tip
13
How can I view a data access page?
Design View
Page View
Web Page Preview
The Design view allows you to change the layout and design of a data access page to make the page easier to use or to enhance the appearance of the page.
The Page view allows you to review, enter and edit information displayed in a data access page.
The Web Page Preview view allows you to display a data access page in your Web browser so you can see how the page will appear on the Web or on your company's intranet.
USING THE WEB PAGE PREVIEW VIEW
Tribute Electronics : ...
Before you can display your data access page in a Web browser, you must save any changes you made to the page.
⁄ Click
to save any changes you made to the data access page.
Customer Orders : D...
12:00 PM
¤ Click in this area to display the data access page in a different view. ‹ Click Web Page Preview.
Tribute Electroni...
Customer Order...
The Microsoft Internet Explorer window appears, displaying the page as it will appear on the Web or on your company's intranet.
Customer Order...
12:00 PM
› When you finish reviewing the page, click to close the page.
287
OPEN A DATA ACCESS PAGE
You can open a data access page to display the contents of the page on your screen. Opening a data access page allows you to review and make changes to the page.
mG
A
Each time you open a data access page, Access will display the most current data from your database in the page. OPEN A DATA ACCESS PAGE
Customer Orders
12:00 PM
Tribute Electronics : ...
⁄ Click Pages in the Database window.
This area displays a list of the data access pages you have created in the database.
¤ Double-click the data access page you want to open.
288
Tribute Electronics : ...
The data access page opens. You can now review and make changes to the page.
Customer Orders
12:00 PM
When you finish reviewing and working with the data access page, click to close the page.
ADD A TITLE
You can add a title to a data access page to describe the information displayed in the page.
Create Data Access Pages
13
ers d r O er m o t Cus
ADD A TITLE
Tribute Electronics: ...
Customer Orders: D...
⁄ Display the data access page you want to add a title to in the Design view. To change the view of a data access page, see page 286.
12:00 PM
¤ Click this area to add a title to the data access page.
Tribute Electronics: ...
A flashing insertion point appears in the area.
‹ Type a title for your data access page.
› Click
to save your change.
Customer Orders: D...
12:00 PM
To remove a title from a data access page, drag the mouse over the title until you highlight the entire title and then press the Delete key.
289
MOVE THROUGH RECORDS
You can move through the records in a data access page to review and edit information.
8
Product ID
Sports Superstore
2
Product ID
Product Name DVD Category:
Video
Unit Price Units In Stock
$139.99
Television Charlotte VideoNC
Unit Price
80
2354 Elm Ave.
Product Name Category:
Units In Stock
Products 2 of 12
28228-
4
3 ame Speakers Home Audio
$225.00
$799.00 ock
125 Customers 8 of 12 Products 3 of 12
Product ID Product Name
Cellular Phone
Category:
Communications
Unit Price Units In Stock
55 Products 4 of 12
$14 125 Products 5 of 12
AD3
PUSH
AD3
POWER
RESET
COMPACT COMPACT
MOVE THROUGH RECORDS
Tribute Electronics : ...
This area displays the number of the current record and the total number of records.
12:00 PM
Customer Orders
⁄ To move to another record, click one of the following buttons. First record Previous record Next record Last record
290
Tribute Electronics : ...
The information for the record you specified appears.
Customer Orders
12:00 PM
Create Data Access Pages
Tip
13
Can I edit the data in my data access page?
Yes. You can edit the data in a data access page as you would edit data on a form. To edit data on a form, see page 146. After you finish making changes to data, click in the data access page to save your changes. When you change data in a data access page, Access will also change the data in the table you used to create the page.
1
Product ID Product Name Headphones Category:
Accessories $19.99
Unit Price Units In Stock
350 Products 1 of 12
If your data access page displays information from more than one table, you may not be able to edit data in the page.
Tribute Electronics : ...
MOVE THROUGH GROUPED RECORDS
If you chose to group data when you created your data access page, a plus sign ( ) appears beside the field you used to group the data. In this example, the records are grouped by state.
Customers
12:00 PM
⁄ To display the information for a record, click the plus sign ( ) beside the field ( changes to ).
Tribute Electronics : ...
The information for one record appears. In this example, the information for a customer from the current state appears. Note: To once again hide the information for the record, click the minus sign ( ) beside the field.
Customers
12:00 PM
To move through the records in the current group, use these buttons. To move through the field used to group the records, use these buttons.
291
APPLY A THEME
Access offers many ready-to-use designs, called themes, that you can use to enhance the overall appearance of a data access page.
22040
COLOR VIEW
of 4 Customers 3
A theme includes a group of design elements including fonts, horizontal lines, links, bullets and background pictures.
Customers 1 of 4
APPLY A THEME
Customer Orders
Tribute Electronics : ...
12:00 PM
⁄ Click Pages in the
¤ Click the data access
Database window.
page you want to apply a theme to.
This area displays a list of the data access pages you have created in the database.
292
‹ Click Design to open the data access page in the Design view.
Tribute Electronics : ...
The data access page appears in the Design view.
› Click Format.
Customer Orders : D...
12:00 PM
ˇ Click Theme. The Theme dialog box appears.
Create Data Access Pages
Why didn't a sample of the theme I selected appear?
Tip
Tip
If a sample of the theme you selected does not appear, the theme is not installed on your computer. To install the theme, click Install in the Theme dialog box.
13
Are there other ways I can change the appearance of a data access page?
When you display a data access page in the Design view, you can change the design of the page as you would change the design of a form. For example, you can bold text, change the font and color of text and add a picture to the page. To change the design of a form, see pages 154 to 169.
Bold Stripes
Countr
y:
Blends
Tribute Electronics : ...
This area displays a list of the available themes.
Á Click the theme you want to apply to your data access page.
Customer Orders : D...
12:00 PM
Tribute Electronics : ...
This area displays a sample of the theme you selected.
The data access page displays the theme you selected.
Note: If a sample does not appear, see the top of this page.
° Click
‡ Click OK to apply the theme to your data access page.
to save your
Customer Orders : D...
12:00 PM
To remove a theme, repeat steps 1 to 8, selecting (No Theme) in step 6.
change.
293
RENAME A DATA ACCESS PAGE
You can change the name of a data access page to better describe the information displayed in the page.
Each data access page in your database must have a unique name. RENAME A DATA ACCESS PAGE
First Quarter Sales
Sales Report
Tribute Electronics: ...
12:00 PM
⁄ Click Pages in the
¤ Click the name of the
Database window.
data access page you want to rename.
This area displays a list of the data access pages you have created in the database.
294
‹ After a few seconds, click the name again or press the F2 key. A black border appears around the name. Note: If you accidentally double-click the name of the data access page, the page will open.
Tribute Electronics: ...
› Type a new name for the data access page and then press the Enter key. The data access page displays the new name.
12:00 PM
Note: Access stores a data access page as a separate file outside of your database. Renaming a data access page in Access renames the shortcut to the file, but does not rename the file itself.
DELETE A DATA ACCESS PAGE
If you no longer need a data access page, you can permanently delete the page from your database.
Create Data Access Pages
13
base
Data
Access stores a data access page as a separate file outside of your database and displays a shortcut to the file in the Database window. When deleting a data access page, you can delete both the shortcut to the file and the file itself or just the shortcut.
DELETE A DATA ACCESS PAGE
Best-Selling Products
12:00 PM
Tribute Electronics: ...
⁄ Click Pages in the Database window. This area displays a list of the data access pages you have created in the database.
¤ Click the name of the data access page you want to delete.
‹ Click
to delete the data access page.
Tribute Electronics: ...
A confirmation dialog box appears.
› Click a button to specify if you want to delete both the shortcut to the file and the file itself or just the shortcut.
12:00 PM
Note: If you select Delete Link and Files in step 4, the Confirm File Delete dialog box will appear. Click Yes to delete the file.
295
INDEX Symbols * (asterisk) add all fields from tables to queries using, 207 find records in queries using, 215 ? (question mark), find records in queries using, 215 < (less than), criteria, 214 <= (less than or equal to), criteria, 214 = (exact matches), criteria, 214 > (greater than), criteria, 214 >= (greater than or equal to), criteria, 214
B back up databases, 28-29 background color, change for controls in forms, 164 for tables, 48 for text in forms, when applying conditional formatting, 171 bold data, in forms, 161 when applying conditional formatting, 171 border styles, of tables, change, 49
A
C
Access. See also specific subject or feature exit, 5 get help with, 30-31 overview, 4 start, 5 toolbars, display or hide, 25 windows, minimize, 24 addresses e-mail, add to tables, 114-115, 118-119 Web page, add to tables, 114-117 alignment of data, in forms, change, 166 And criteria filter records using, 188, 189 find records in queries using, 213 appearance of objects in Database window, change, 21 of tables, change, 48-49 asterisks (*) add all fields from tables to queries using, 207 find records in queries using, 215 AutoCorrect feature, 61 AutoForm Wizard, create forms using, 136-137 autoformats, apply to forms, 172-173 to reports, 261 AutoNumber data type, 83 primary key type, 127 AutoReport Wizard, create reports using, 254-255 Average, calculate in PivotChart, 243 in PivotTable, 236-237 Avg, calculate in queries, 198-199, 223 in reports, 250
calculations perform in PivotChart, 243 in PivotTable, 236-237 in queries, 198-199, 218-219 in reports, 250-251 remove from PivotTable, 237 cancel changes in forms, 147, 167 in tables, 57 captions, add to fields, in tables, 90 cascade delete related records, 133 cascade update related fields, 133 CD-R discs, back up databases using, 29 CD-RW discs, back up databases using, 29 cells in forms, replace all data in, 147 in tables add effects, 48 replace data in, 57 select, 55 select data in, 55 zoom into, 58 center data, in forms, 166 Chart Field List dialog box, move, 241 charts. See PivotChart view clear fields from queries, 207 Clipboard task pane, 63 close Access, 5 data access pages, 288 forms, 144 objects, 21 preview window, 267 queries, 204 reports, 256 tables, 42
296
color, change in forms of controls, 164-165 data, when applying conditional formatting, 171 mailing labels, of text, change, 275 in tables background, 48 data, 67 gridlines, 49 Columnar AutoForm type, 137 AutoReport type, 255 columns. See also fields line style under headers, change, 49 lookup create, 106-109 use, 109 width, change, 43 conditional formatting, in forms apply, 170-171 remove, 171 controls, in forms color of background, change, 164, 165 of text, change, 165 delete, 156 move, 154 resize, 155 copy data in tables, 62-63 Count, calculate in PivotChart, 243 in PivotTable, 236-237 in queries, 199, 223 criteria And, 188, 189, 213 examples, 214-215 for filtering records by form, 187, 188-189 find records in queries using, 211, 212-213 Or, 189, 212, 213 Currency, data type, 83 D data. See also records; text in data access pages edit, 291 group, 282 find, 178-179 in forms alignment, change, 166 bold, 161 in cells, replace all, 147
color, change, 165 delete, 146 edit, 146-147 font, change, 162 insert, 146 italicize, 161 print only, 268-269 size, change, 163 underline, 161 in queries edit, 195 summarize, 222-225 replace, 180-181 in reports group, 248 perform calculations, 250-251 print only, 268-269 in tables color, change, 67 copy, 62-63 delete, 56 deselect, 55 edit, 56-57 find, 178-179 font, change, 66 insert, 56 move, 62-63 move through, 52-53 replace, 180-181 in cells, 57 require for fields, 92-93 select, 54-55 size, change, 66 spelling, check, 60-61 style, change, 66 types, for fields, change, 82-83 underline, 66 data access pages create, 280-285 data edit, 291 group, 282 as database objects, 21 delete, 295 open, 288 as part of database, 7 records move through, 290-291 sort, 282-283 rename, 294 save, 284-285
297
INDEX themes apply, 292-293 remove, 293 titles add, 289 remove, 289 view, change, 286-287 Database window display, 20 use, 20-21 Database Wizard, create databases using, 10-15 databases back up, 28-29 create blank, 16-17 using Database Wizard, 10-15 open, 18-19 recently used, 19 overview, 4 parts of, 6-7 plan, 8-9 restore from backup copies, 29 search for, 26-27 templates obtain on Internet, 11 select recently used, 11 Datasheet, AutoForm type, 137 Datasheet view create tables in, 34-37 of forms, 153 of queries, 202, 203 of tables, 74, 75 Date/Time, data type, 83 decimal places, change number of, for fields, 88-89 default values, set for fields in tables, 91 delete. See also remove data in forms, 146 in tables, 56 data access pages, 295 fields from queries, 208 from tables, 47, 78 objects, 23 pictures from forms, 169 from reports, 263 records, from forms, 149 relationships between tables, 131 dependencies for objects, view, 124-125 descriptions, add to fields, 81 deselect data, in tables, 55
298
Design view create queries in, 192-195 of data access pages, 286, 287 of forms, 152, 153 of queries, 202, 203 of reports, 258, 259 of tables, 74, 75 desktop, 17 dialog boxes, obtain help when using, 31 display. See also view Database window, 20 field properties, 80 hidden fields, in tables, 69 highest or lowest values in queries, 216-217 legend, in PivotChart, 241 subdatasheets in tables, 59 toolbars, 25 E edit data in data access pages, 291 in forms, 146-147 in tables, 56-57 mailing labels, 277 effects, add to cells in tables, 48 e-mail addresses, create hyperlinks for in fields, 118-119 exit Access, 5 expressions, enter for calculations, 218-219 F field names, in tables, 35 change, 44 fields. See also columns consider when planning databases, 9 in forms add, 158 order of, 139 in PivotChart view add, 239-241 remove, 241 in PivotTable view add, 233-235 remove, 235 in queries add, 206-207 delete, 208 hide, 209 rearrange, 205 in tables add, 46, 76-77 captions, add, 90
create to store hyperlinks, 114-115 to store pictures, 102-105 data type, change, 82-83 decimal places, change number, 88-89 default value, set for, 91 delete, 47, 78 descriptions, add, 81 format, select, 84-85 freeze, 70-71 hide, 68, 69 hyperlinks add to, 116-117, 118-119 remove from, 117, 119 input masks, create custom, 100-101 using wizard, 96-99 lookup columns create, 106-109 use, 109 overview, 6, 35 properties, display, 80 rearrange, 45, 79 redisplay, 69 rename, 44 require data entry for, 92-93 scroll through, 53 select, 54 size, change, 86-87 smart tags, set up, 120-121 unfreeze, 71 validation rules, add, 94-95 Yes/No, create, 110-113 files, add hyperlinks for, to fields, 116-117 filter records by exclusion, 185 by form, 186-189 by input, 184 by selection, 182-183 Find and Replace dialog box, move, 181 find. See also search data, 178-179 records, in queries, using criteria, 211, 212-213 unmatched records in queries, 226-229 First, calculate, in queries, 223 floppy disks, back up databases using, 28 font of data, change in forms, 162 on mailing labels, 274 in tables, 66 Form view, of forms, 152, 153 Form Wizard, create forms using, 138-143 format for fields, select, 84-85
forms appearance, change, 49 autoformats, apply, 172-173 conditional formatting apply, 170-171 remove, 171 controls color, change, 164-165 delete, 156 move, 154 resize, 155 create using AutoForm Wizard, 136-137 using Form Wizard, 138-143 data alignment, change, 166 bold, 161 in cells, replace all, 147 color, change, 165 delete, 146 edit, 146-147 find, 178-179 font, change, 162 insert, 146 italicize, 161 replace in, 180-181 size, change, 163 underline, 161 delete, 23 fields, add, 158 labels add, 159 text, change, 160 linked, create, 140-142 margins, change, 268-269 as objects in Database window, 21 open, 144 order of fields in, 139 as part of database, 7 pictures add to, 168-169 delete, 169 preview before printing, 266-267 print, 270-271 data only, 268-269 records add, 148 delete, 149 filter by exclusion, 185 by form, 186-189 by input, 184 by selection, 182-183 move through, 145 sort, 176-177 rename, 22
299
INDEX save, 137 size, change, 157 subforms create, 140-142 move through, 143 text color, change, 165 undo changes, 147, 167 views, change, 152-153 freeze fields, in tables, 70-71 G greater than (>), criteria, 214 greater than or equal to (>=), criteria, 214 gridlines, in tables color, change, 49 remove, 48 styles, change, 49 group data in data access pages, 282 in reports, 248 H help, obtain, 30-31 when working in dialog boxes, 31 hide fields in queries, 209 in tables, 68, 69 toolbars, 25 Hyperlink data type, 83 field, create, 114-115 hyperlinks, in tables add to fields, 116-117, 118-119 remove from fields, 117, 119 select, 117, 119 I input masks characters for creating, 101 create custom, 100-101 using wizard, 96-99 remove, 101 use, 99, 101 insert data in forms, 146 in tables, 56 intranets, 116, 280 italicize data in forms, 161 when applying conditional formatting, 171 text in mailing labels, 274
300
K keyboard, use to move through data in tables, 53 keys, primary. See primary keys L labels in forms add to, 159 color, change, 164-165 delete, 156 move, 154 resize, 155 text, change, 160 mailing. See mailing labels landscape orientation, of reports, 253 Last, calculate, in queries, 223 Layout Preview view, of reports, 259 left align data, in forms, 166 legend, display in PivotChart, 241 less than (<), criteria, 214 less than or equal to (<=), criteria, 214 linked forms, create, 140-142 links. See Hyperlinks lookup columns create, 106-109 use, 109 M magnify pages, when previewing, 267 reports, 260 mailing labels create, 272-277 edit, 277 print, 277 text color, change, 275 margins, change, 268-269 Max, calculate in PivotChart, 243 in PivotTable, 236-237 in queries, 198-199, 223 in reports, 250 Memo, data type, 83 Min, calculate in PivotChart, 243 in PivotTable, 236-237 in queries, 198-199, 223 in reports, 250 minimize windows, 24 move Chart Field List dialog box, 241 controls, in forms, 154
data in tables, 62-63 Find and Replace dialog box, 181 PivotTable Field List dialog box, 235 through data in tables, 52-53 pages of reports, 257 records in data access pages, 290-291 in forms, 145 in tables, 52 multiple-field, primary key type, 127 My Computer, 17 My Documents, 17 My Network Places, 17 My Recent Documents, 17 N names of fields, in tables, 35 change, 44 Number, data type, 83 number fields change decimal places for, 88-89 size, change, 87 O objects appearance in Database window, change, 21 close, 21 delete, 23 dependencies, view, 124-125 open, 20-21 rename, 22 OLE Object, data type, 83 one-to-many, relationship type, 131 one-to-one, relationship type, 131 open data access pages, 288 forms, 144 objects, 20-21 queries, 204 reports, 256 tables, 42 OpenType fonts, 67 operators for entering parameters in queries, 221 use when applying conditional formatting, 171 Or criteria filter records using, 189 find records in queries using, 212, 213 order of fields in forms, 139 orientation of printed pages, change, 268-269 for reports, 253 Overtype feature, 147
P page setup options, change, 268-269 Page view, of data access pages, 286, 287 pages. See data access pages paper size, select, before printing, 268-269 paper source, select, before printing, 268-269 parameters, use in queries, 220-221 pictures in forms add, 168-169 delete, 169 in reports add, 262-263 delete, 263 in tables add to records, 102-105 remove from records, 105 view, 105 PivotChart AutoForm type, 137 calculations, change, 243 chart type, change, 242 fields add, 239-241 remove, 241 legend, display, 241 view of forms, 153 of queries, 203 of tables, 75 use, 238-243 PivotTable AutoForm type, 137 calculations perform, 236-237 remove from, 237 Field List dialog box, move, 235 fields add, 233-235 remove, 235 view of forms, 153 of queries, 203 of tables, 75 use, 232-237 portrait orientation, of reports, 253 preview data before printing, 266-267 primary key consider when planning databases, 9 create, when creating tables, 36, 39 overview, 39 set, for tables, 126-127
301
INDEX print information, 270-271 mailing labels, 277 options, change, 268-269 Print Preview feature, use, 266-267 Print Preview view, of reports, 258, 259 properties, for fields, display, 80 Property Update Options button, 81, 85, 101, 113 Q queries add tables to, when creating in Design view, 192-193 appearance, change, 49 calculations, perform, 198-199, 218-219 create in Design view, 192-195 using Simple Query Wizard, 196-201 data find, 178-179 replace in, 180-181 summarize, 222-225 delete, 23 fields add, 206-207 clear, 207 delete, 208 hide, 209 rearrange, 205 headings, print, 268-269 margins, change, 268-269 as objects in Database window, 21 open, 204 parameters, use, 220-221 as part of database, 7 preview before printing, 266-267 print, 270-271 records display highest or lowest values, 216-217 filter by exclusion, 185 by form, 186-189 by input, 184 by selection, 182-183 find unmatched, 226-229 using criteria, 211, 212-213 sort, 176-177, 210 rename, 22 run, 194-195 save, 195 view, change, 202-203 question mark (?), find records in queries using, 215
302
R rearrange fields in queries, 205 in tables, 45, 79 records. See also data; text criteria for filtering by form, 187, 188-189 in data access pages move through, 290-291 sort, 282-283 filter by exclusion, 185 by form, 186-189 by input, 184 by selection, 182-183 in forms add to, 148 delete, 149 move through, 145 in queries display highest or lowest values, 216-217 find unmatched, 226-229 using criteria, 211, 212-213 grouped, summarize data for, 224-225 sort, 210 in reports, sort, 249 sort, 176-177 remove, 177 in tables add to, 64 delete, 65 move through, 52 overview, 6, 35 pictures add to, 103-105 remove, 105 view, 105 select, 54 redisplay fields, in tables, 69 referential integrity, enforce in tables, 132-133 relationships between tables consider when planning databases, 9 create, 128-131 delete, 131 remove. See also delete bolding, from form data, 161 calculations from PivotTable, 237 conditional formatting from forms, 171 fields from PivotChart, 241 from PivotTable, 235 gridlines in tables, 48 hyperlinks, from fields, in tables, 117, 119 input masks, 101
S
search for databases, 26-27 select, in tables cells, 55 data, 54-55 fields, 54 hyperlinks, in fields, 117, 119 records, 54 Simple Query Wizard, create queries using, 196-201 single-field, primary key type, 127 size, change for data in forms, 163 in tables, 66 for fields in tables, 86-87 for forms, 157 for text on mailing labels, 274 smart tags, use, 120-121 sort query results, 210 records, 176-177 in data access pages, 282-283 in reports, 249 remove, from records, 177 spelling, check in tables, 60-61 SQL view, of queries, 203 Standard Deviation, calculate in PivotChart, 243 in PivotTable, 236-237 Standard Deviation Population, calculate in PivotChart, 243 in PivotTable, 236-237 start Access, 5 StDev, calculate, in queries, 223 style of data in tables, change, 66 subdatasheets, display in tables, 59 subforms autoformat, apply, 153 create, 140-142 move through, 143 Sum, calculate in PivotChart, 243 in PivotTable, 236-237 in queries, 198-199, 223 in reports, 250 summarize data, in queries, 222-225 symbols, next to records in tables, 57
save
T
italics, from form data, 161 pictures from tables, 105 sort from records, 177 tables, from Relationships window, 129 themes, from data access pages, 293 titles, from data access pages, 289 underlines, from form data, 161 rename data access pages, 294 fields, in tables, 44 objects, 22 replace data, 180-181 in cells, in forms, 147 Report Wizard, create reports using, 246-253 reports autoformats, apply, 261 calculations, perform, 250-251 create using AutoReport Wizard, 254-255 using Report Wizard, 246-253 delete, 23 group data in, 248 margins, change, 268-269 move through pages, 257 as objects in Database window, 21 open, 256 as part of database, 7 pictures add, 263-263 delete, 263 preview before printing, 266-267 print, 270-271 data only, 268-269 rename, 22 save, 255 sort records in, 249 view, change, 258-259 zoom in or out, 260 resize controls, in forms, 155 restore databases, from backup copies, 29 windows, 24 right align data, in forms, 166 run queries, 194-195
data access pages, 284-285 forms, 137 queries, 195 reports, 255 tables, 36 scroll through fields, in tables, 53 records, in tables, 53
Table Wizard, create tables using, 38-41 tables add to queries, when creating in Design view, 192-193 appearance, change, 48-49 background color, change, 48 border styles, change, 49
303
INDEX cells effects, add to, 48 select, 55 data in, 55 zoom into, 58 close, 42 columns line style under headers, change, 49 width, change, 43 consider when planning databases, 8 create in Datasheet view, 34-37 using Table Wizard, 38-41 data color, change, 67 copy, 62-63 delete, 56 deselect, 55 edit, 56-57 find, 178-179 font, change, 66 insert, 56 move, 62-63 move through, 52-53 replace, 180-181 in cells, 57 require for fields, 92-93 select, 54-55 size, change, 66 spelling, check, 60-61 style, change, 66 types, for fields, change, 82-83 underline, 66 as database objects, 21 delete, 23 fields add to, 46, 76-77 captions, add, 90 create to store hyperlinks, 114-115 to store pictures, 102-103 data type, change, 82-83 decimal place, change number, 88-89 default value, set for, 91 delete, 47, 78 descriptions, add, 81 format, select, 84-85 freeze, 70-71 hide, 68, 69 hyperlinks add to, 116-117, 118-119 remove from, 117, 119 input masks, create custom, 100-101 using wizard, 96-99
304
lookup columns create, 106-109 use, 109 overview, 6, 35 properties, display, 80 rearrange, 45, 79 redisplay, 69 rename, 44 require data entry for, 92-93 scroll through, 53 select, 54 size, change, 86-87 smart tags, set up for, 120-121 unfreeze, 71 validation rules, add, 94-95 Yes/No, create, 110-113 gridlines color, change, 49 remove, 48 styles, change, 49 headings, print, 268-269 margins, change, 268-269 open, 42 as part of database, 6 parts of, 35 pictures add to, 102-105 remove from, 105 preview before printing, 266-267 primary key, set, 126-127 print, 270-271 records add, 64 delete, 65 filter by exclusion, 185 by form, 186-189 by input, 184 by selection, 182-183 select, 54 sort, 176-177 referential integrity, enforce, 132-133 relationships create, 128-131 delete, 131 remove from Relationships window, 129 rename, 22 save, 36 smart tags, use, 120-121 subdatasheets, display, 59 symbols next to records, 57 undo changes, 57 view, change, 74-75
Tabular AutoForm type, 137 AutoReport type, 255 templates, for databases obtain on Internet, 11 select recently used, 11 text. See also data; records fields, size, change, 86 in forms color, change, 165 on labels, change, 160 on mailing labels appearance, change, 274 color, change, 275 Text, data type, 83 text boxes, on forms color, change, 164-165 delete, 156 move, 154 resize, 155 themes, on data access pages apply, 292-293 remove, 293 titles, on data access pages, add or remove, 289 toolbars, display or hide, 25 Toolbox toolbar, display, 168 U underline data in forms, 161 when applying conditional formatting, 171 in mailing labels, 274 in tables, 66 underlines for column headers in tables, style, change, 49 undo changes in forms, 147, 167 in tables, 57 unfreeze fields, in tables, 71
pictures, linked to tables, 105 subdatasheets in tables, 59 toolbars, 25 views. See also specific view change for data access pages, 286-287 for forms, change, 152-153 for objects in Database window, change, 21 for queries, change, 202-203 for reports, change, 258-259 for tables, change, 74-75 W Web Page Preview view, of data access pages, 287 Web pages. See also data access pages add hyperlinks for, to tables, 116-117 weight, of text in mailing labels, change, 274 width of columns in tables, change, 43 wildcards, use to find records in queries, 215 windows, minimize, 24 Y Yes/No data type, 83 fields, create in tables, 110-113 Z zero-length strings, 93 zoom. See also magnify in or out, of reports, 260 into cells in tables, 58
V validation rules, add to fields in tables, 94-95 Var, calculate, in queries, 223 Variance, calculate in PivotChart, 243 in PivotTable, 236-237 Variance Population, calculate in PivotChart, 243 in PivotTable, 236-237 view Database window, 20 field properties, 80 hidden fields, in tables, 69 highest or lowest values in queries, 216-217 legend, in PivotChart, 241 object dependencies, 124-125
305
PIANO MARAN ILLUSTRATED™ Piano is an information-packed resource for people who want to learn to play the piano, as well as current musicians looking to hone their skills. Combining full-color photographs and easy-to-follow instructions, this guide covers everything from the basics of piano playing to more advanced techniques. Not only does MARAN ILLUSTRATED™ Piano show you how to read music, play scales and chords and improvise while playing with other musicians, it also provides you with helpful information for purchasing and caring for your piano.
ISBN: 1-59200-864-X Price: $24.99 US; $33.95 CDN Page count: 304
DOG TRAINING MARAN ILLUSTRATED™ Dog Training is an excellent guide for both current dog owners and people considering making a dog part of their family. Using clear, step-by-step instructions accompanied by over 400 full-color photographs, MARAN ILLUSTRATED™ Dog Training is perfect for any visual learner who prefers seeing what to do rather than reading lengthy explanations. Beginning with insights into popular dog breeds and puppy development, this book emphasizes positive training methods to guide you through socializing, housetraining and teaching your dog many commands. You will also learn how to work with problem behaviors, such as destructive chewing.
ISBN: 1-59200-858-5 Price: $19.99 US; $26.95 CDN Page count: 256
KNITTING & CROCHETING MARAN ILLUSTRATED™ Knitting & Crocheting contains a wealth of information about these two increasingly popular crafts. Whether you are just starting out or you are an experienced knitter or crocheter interested in picking up new tips and techniques, this information-packed resource will take you from the basics, such as how to hold the knitting needles or crochet hook, to more advanced skills, such as how to add decorative touches to your projects. The easy-to-follow information is communicated through clear, step-bystep instructions and accompanied by over 600 full-color photographs—perfect for any visual learner.
n mara
Knitting & Crocheting
ISBN: 1-59200-862-3 Price: $24.99 US; $33.95 CDN Page count: 304
YOGA MARAN ILLUSTRATED™ Yoga provides a wealth of simplified, easy-to-follow information about the increasingly popular practice of Yoga. This easy-to-use guide is a must for visual learners who prefer to see and do without having to read lengthy explanations. Using clear, step-by-step instructions accompanied by over 500 full-color photographs, this book includes all the information you need to get started with yoga or to enhance your technique if you have already made yoga a part of your life. MARAN ILLUSTRATED™ Yoga shows you how to safely and effectively perform a variety of yoga poses at various skill levels, how to breathe more efficiently and much more.
ISBN: 1-59200-868-2 Price: $24.99 US; $33.95 CDN Page count: 320
WEIGHT TRAINING MARAN ILLUSTRATED™ Weight Training is an information-packed guide that covers all the basics of weight training, as well as more advanced techniques and exercises. MARAN ILLUSTRATED™ Weight Training contains more than 500 full-color photographs of exercises for every major muscle group, along with clear, step-by-step instructions for performing the exercises. Useful tips provide additional information and advice to help enhance your weight training experience. MARAN ILLUSTRATED™ Weight Training provides all the information you need to start weight training or to refresh your technique if you have been weight training for some time.
ISBN: 1-59200-866-6 Price: $24.99 US; $33.95 CDN Page count: 320
GUITAR MARAN ILLUSTRATED™ Guitar is an excellent resource for people who want to learn to play the guitar, as well as for current musicians who want to fine tune their technique. This full-color guide includes over 500 photographs, accompanied by step-by-step instructions that teach you the basics of playing the guitar and reading music, as well as advanced guitar techniques. You will also learn what to look for when purchasing a guitar or accessories, how to maintain and repair your guitar, and much more. Whether you want to learn to strum your favorite tunes or play professionally, MARAN ILLUSTRATED™ Guitar provides all the information you need to become a proficient guitarist.
ISBN: 1-59200-860-7 Price: $24.99 US; $33.95 CDN Page count: 320
Visit www.maran.com/guitar to download MP3 files you can listen to and play along with for all the chords, scales, exercises and practice pieces in the book.
Did you like this book? MARAN ILLUSTRATED™ offers books on the most popular computer topics, using the same easy-to-use format of this book. We always say that if you like one of our books, you’ll love the rest of our books too! Here’s a list of some of our best-selling computer titles: Guided Tour Series - 240 pages, Full Color MARAN ILLUSTRATED’s Guided Tour series features a friendly disk character that walks you through each task step by step. The full-color screen shots are larger than in any of our other series and are accompanied by clear, concise instructions.
MARAN ILLUSTRATED™ Computers Guided Tour MARAN ILLUSTRATED™ Windows XP Guided Tour
mG
ISBN
Price
1-59200-880-1 1-59200-886-0
$24.99 US/$33.95 CDN $24.99 US/$33.95 CDN
MARAN ILLUSTRATED™ Series - 320 pages, Full Color This series covers 30% more content than our Guided Tour series. Learn new software fast using our step-by-step approach and easy-to-understand text. Learning programs has never been this easy!
ILLUSTRATED™ ILLUSTRATED™ ILLUSTRATED™ ILLUSTRATED™
Windows XP Office 2003 Excel 2003 Access 2003
Service
Pack Two
On Off Volume
ffO emuloV
Microsoft
R
Win dow XP Home Editio s n
WindowsXP
MARAN MARAN MARAN MARAN
Microsoft POWER
nO
TM
R
start
t Microsof
start
ISBN
Price
1-59200-870-4 1-59200-890-9 1-59200-876-3 1-59200-872-0
$24.99 US/$33.95 CDN $29.99 US/$40.95 CDN $24.99 US/$33.95 CDN $24.99 US/$33.95 CDN
101 Hot Tips Series - 240 pages, Full Color Progress beyond the basics with MARAN ILLUSTRATED’s 101 Hot Tips series. This series features 101 of the coolest shortcuts, tricks and tips that will help you work faster and easier.
MARAN ILLUSTRATED™ Windows XP 101 Hot Tips
ISBN
Price
1-59200-882-8
$19.99 US/$26.95 CDN