Download presentation
Presentation is loading. Please wait.
Published byRosamund Harrington Modified over 7 years ago
1
Instructor: Eng. Juan E. Crespo Introduction to MS Access 2007 1 Copyright Crespo Technology Services Group, Inc.
2
Course Outline Lesson 1: Exploring the Microsoft® Office Access™ 2007 Environment Examine Database Concepts Explore the User Interface Explore the Ribbon Customize the Access Environment Obtain Help Use an Existing Access Database Lesson 2: Designing a Database Describe the Relational Database Design Process Define Database Purpose Review Existing Data Determine Fields Group Fields into Tables Normalize Data Designate Primary and Foreign Keys Determine Table Relationships Lesson 3: Building a Database Create a New Database Create a Table Manage Tables Create a Table Relationship Save a Database as a Previous Version Lesson 4: Managing Data in a Table Modify Table Data Sort Records Work with Subdatasheets Lesson 5: Querying a Database Filter Records Create a Query Add Criteria to a Query Add a Calculated Field to a Query Perform Calculations on a Record Grouping Lesson 6: Designing Forms View Data Using an Access Form Create a Form Modify the Design of a Form Lesson 7: Generating Reports View an Access Report Create a Report Add a Custom Calculated Field to a Report Format the Controls in a Report Apply an AutoFormat to a Report Prepare a Report for Print 2 Copyright Crespo Technology Services Group, Inc.
3
Exploring the Microsoft® Office Access™ 2007 Environment Copyright Crespo Technology Services Group, Inc. 3
4
Database Concepts Terms Database: collection of objects that allow you to store data, organize it and retrieve it in any way you want. It may contain: Tables: structure that allow you to organize the data so that it's easy to find later Forms: let you input the data into the tables Reports: print selected information from the tables Relational Database: stores data in various interrelated tables where data is stored, accessed and presented without affecting the structure 4 Copyright Crespo Technology Services Group, Inc.
5
Database Concepts Last NameFirst NameStudent IDCity PérezJuan101010Utuado CrespoCarlos802-91-2515Aguadilla 5 Copyright Crespo Technology Services Group, Inc.
6
Database Concepts Database Design Reason for the database: There are usually two reasons for a database: Data management: Add, remove or modify data Data analysis: Analyze information and trends Database content 6 Copyright Crespo Technology Services Group, Inc.
7
Explore the User Interface MS Access 2007 is a Database Management System It allows the user to: Retrieve and update data Present data sorted or grouped Import or export data from various sources including the Internet 7 Copyright Crespo Technology Services Group, Inc.
8
Explore the User Interface The user interface is composed of: Office button Quick access tool bar The ribbon The navigation pane The MS Office window frame Dialog box launcher 8 Copyright Crespo Technology Services Group, Inc.
9
Explore the User Interface 9 Copyright Crespo Technology Services Group, Inc.
10
Explore the User Interface 10 Copyright Crespo Technology Services Group, Inc.
11
Explore the Ribbon Home Tab Views Clipboard Font Rich Text Records Sort & Filter Find 11 Copyright Crespo Technology Services Group, Inc.
12
Explore the Ribbon Create Tab Tables Forms Reports Other 12 Copyright Crespo Technology Services Group, Inc.
13
Explore the Ribbon External Data Tab Import Export Collect Data SharePoint List 13 Copyright Crespo Technology Services Group, Inc.
14
Explore the Ribbon Database Tools Tab Macro Show/Hide Analyze Move Data Database Tools 14 Copyright Crespo Technology Services Group, Inc.
15
Use an Existing Database Tables are composed of three elements Fields: these are the table columns Records: these are the table rows Values: A single piece of data Student IDLast NameFirst Name 101010PérezJuan 802-91-2154CrespoCarlos 010101CamposDiana 15 Copyright Crespo Technology Services Group, Inc.
16
Use an Existing Database Queries Request Information Requires fields and table names Can include conditions Can be reused Can perform calculations Student IDLast NameFirst Name 101010PérezJuan 802-91-2154CrespoCarlos 010101CamposDiana 16 Copyright Crespo Technology Services Group, Inc.
17
Last NameFirst NameDept. CrespoCarlosIS CamposDianaIS Use an Existing Database Recordset Is a table Displays smaller set of records Can come from a table or query Student IDLast Name First Name Birth Date Dept.City 101010PérezJuan01/01/70HUMUtuado 802-91-2154CrespoCarlos07/16/73ISAguadilla 010101CamposDiana03/20/78ISLares 123456FigueroaRicardo10/31/76ADMCoamo 131313RiveraDavid11/02/80ADMUtuado 17 Copyright Crespo Technology Services Group, Inc.
18
Use an Existing Database Forms Used to display and edit data Based on tables or queries Can be customized Can include Calculations Graphics Other objects 18 Copyright Crespo Technology Services Group, Inc.
19
Use an Existing Database Report Screen output of data Presented as specified by the user Data comes from tables or queries Can perform calculations and display results Can be printed 19 Copyright Crespo Technology Services Group, Inc.
20
Customize the Access Environment Can be found on the MS Office button 20 Copyright Crespo Technology Services Group, Inc.
21
Customize the Access Environment Various options to customize the MS Access environment Database objects Security Quick Access toolbar 21 Copyright Crespo Technology Services Group, Inc.
22
Obtain Help Access Help Complete manual on features Quick and easy access to answers 22 Copyright Crespo Technology Services Group, Inc.
23
Design a Database Copyright Crespo Technology Services Group, Inc. 23
24
Relational Database Designing Process Sequential process for developing a database plan This process consists of seven steps Database purpose Review existing data Create list of fields Organize fields into tables Enter sample data and verify if changes are required Designate primary and foreign keys Determine table relationships 24 Copyright Crespo Technology Services Group, Inc.
25
Define Database Purpose Statement of purpose Defines the scope of a database Helps guide the design Implies the kind of data Determine the probable users 25 Copyright Crespo Technology Services Group, Inc.
26
Review Existing Data Copyright Crespo Technology Services Group, Inc. 26 Relevant data to the statement of purpose Can be in paper or electronic Paper Internal Business Forms Government Forms Invoices Electronic Spreadsheets Word documents Databases (Access, MS SQL, Oracle, etc.) Web pages
27
Determine Fields Copyright Crespo Technology Services Group, Inc. 27 The required fields depend on the information required by the user Reports Summary information
28
Group Fields Into Tables Copyright Crespo Technology Services Group, Inc. 28 Business Rules Policies and procedures that govern operation of an organization Define methods for data entry in a database Define a standard naming convention for objects. Example: Student name object can be S_Fname and the lastname can be S_Lname
29
Database Design Class Exercise You are required to develop a database to keep track of the books being lent by the university library. Assumptions Only students are allowed to take books The books can only be lent for two weeks No other service will be tracked through this database 29 Copyright Crespo Technology Services Group, Inc.
30
Database Design Class Exercise Develop a list of data required for this database How many tables are required? Why? What information is required for each table? 30 Copyright Crespo Technology Services Group, Inc.
31
Normalize Data Copyright Crespo Technology Services Group, Inc. 31 Normalization Process organizing data in a database Optimizes table structure Refining database by reducing complex data into simple table structures Optimizes by Eliminate redundancy Eliminate inconsistency dependency between tables
32
Normalize Data Copyright Crespo Technology Services Group, Inc. 32 Break data into smallest values possible Assure data is not repeated Break repeated data into separate tables Avoid empty fields as much as possible Consistent references in tables (naming convention)
33
De-normalization Copyright Crespo Technology Services Group, Inc. 33 Definition Combining tables into a bigger table Uses Make queries run faster Keep similar data together Keep table structure simple
34
Designate Primary and Foreign Keys Copyright Crespo Technology Services Group, Inc. 34 Primary Key Field with unique values Values identify each record Used to create relationships between tables Can be of any data type except memo, OLE or Attachment Can never be blank Values do not change or have duplicates
35
Designate Primary and Foreign Keys Copyright Crespo Technology Services Group, Inc. 35 Composite Key Made of the union of two unique fields Foreign Key Field that relates to primary key of another table Primary key acts as record index Helps implement relationship between tables Foreign key helps establish relationship with primary key
36
Designate Primary and Foreign Keys Class Exercise Define a primary and foreign key for each table. This field identifies each individual in a unique way. List any field that contains a limited list of items. Example: City or state. Define default values when possible. Example: 90% of students will be from PR. 36 Copyright Crespo Technology Services Group, Inc.
37
Determine Table Relationships Copyright Crespo Technology Services Group, Inc. 37 Representation of association among data contained within tables Helps poll matching fields One-to-one relationship Primary key and foreign key are unique One-to-many relationship Primary key unique with many foreign key values
38
Building a Database Copyright Crespo Technology Services Group, Inc. 38
39
Create a Database Copyright Crespo Technology Services Group, Inc. 39 To create a database Open Access 2007 In the Getting Started screen select blank database Write database name and select location. Press Create
40
Create a Table Copyright Crespo Technology Services Group, Inc. 40 Access creates a new table when a new blank database is created New tables can be created by selecting the table icon on the Create tab
41
Table Views Copyright Crespo Technology Services Group, Inc. 41 Tables can be viewed in several ways. The two most common views are: Datasheet: This is the default view and presents record values Design: This presents the table and field properties but does no present record values
42
Field Insertion Feature Copyright Crespo Technology Services Group, Inc. 42 Allows adding new fields from datasheet view Write the field name in the column header Repeat for each field
43
Data Types Copyright Crespo Technology Services Group, Inc. 43 Text: Contains characters up to 255 Memo: Advanced text field. Can hold up to 2 GB of data with rich text formatting Numbers: Numeric values up to 16 bytes Date/Time: Stores and manipulates date and time values Currency: Monetary values AutoNumber: Automatically creates a numeric value with new records. Are usually used as primary keys. Yes/No: Boolean information (true or false) Hyperlink: Stores web addresses Attachment: Add files to a record Multivalued: Can have more than one value
44
New Fields Copyright Crespo Technology Services Group, Inc. 44 Fields can be added through: Field insertion feature Design view Multivalued fields are added through the Lookup Wizard
45
Creating Tables Copyright Crespo Technology Services Group, Inc. 45 Create the tables for the books circulation class exercise Use the datasheet view as well as the design view
46
Table Maintenance Copyright Crespo Technology Services Group, Inc. 46 Tables can be: Deleted Renamed Exported Add a description in the Table Properties Dialog
47
Table Properties Copyright Crespo Technology Services Group, Inc. 47 Allows for a detailed description of the table Presents information about the table Create date Modified date Allows to hide a table Allows for row tracking when used by multiple simultaneous users
48
Referential Integrity Copyright Crespo Technology Services Group, Inc. 48 Process to ensure data validity across two tables It is enforced by ensuring values in a foreign field have corresponding values in the primary key Referential integrity prevents the entering of invalid data Benefits of Referential Integrity Avoid data loss Avoid updating data
49
Referential Integrity Copyright Crespo Technology Services Group, Inc. 49 Referential integrity between two table can be set if: Both tables are in the same database The matching field is a primary key in one table or has a unique index The related fields have the same data type
50
Table Relationships Copyright Crespo Technology Services Group, Inc. 50 In the Database Tools tab select relationships If no relationship exists, Access brings the Show Tables or Queries dialog to add them to the relationship Once added, drag the primary key to the foreign key. This brings the Edit relationships dialog Referential integrity can be enforced here A line is drawn between tables to indicate relationship
51
Table Relationships Copyright Crespo Technology Services Group, Inc. 51 Create the table relationships for the books circulation class exercise Enforce referential integrity as required
52
Save a Database in a Previous Version Copyright Crespo Technology Services Group, Inc. 52 In the Office Button menu select Save As There are several database format available : Access 2007 Access 2002-2003 Access 2000
53
Managing Data in a Table Copyright Crespo Technology Services Group, Inc. 53
54
Modifying Data Copyright Crespo Technology Services Group, Inc. 54 Users can: Search for records Replace Data in records Add records Delete Records Modify Records
55
Find Command Copyright Crespo Technology Services Group, Inc. 55 Helps locate specific data. Has various find options
56
Replace Command Copyright Crespo Technology Services Group, Inc. 56 Helps replace specific data with new data Has various replace options
57
Totals Features Copyright Crespo Technology Services Group, Inc. 57 Provides simple math functions to the tables
58
Sorting Records Copyright Crespo Technology Services Group, Inc. 58 Can sort data Ascending Descending The order is based on Numeric information Alphanumeric information
59
Subdatasheets Copyright Crespo Technology Services Group, Inc. 59 Datasheet nested within another datasheet Contains data related to the first datasheet Subdatasheet presence is indicated by + sign on the row
60
Copyright Crespo Technology Services Group, Inc. 60
61
Managing Data Copyright Crespo Technology Services Group, Inc. 61 Class Exercise Fill the created tables with at least 10 records each Delete at least 1 record from each table Modify at least 1 record from each table
62
Queriyng a Database Copyright Crespo Technology Services Group, Inc. 62
63
Querying a Database Copyright Crespo Technology Services Group, Inc. 63 Looking for data in a database is difficult unless there is mechanism for extracting and isolating is A database is effective when data can be retrieved as easily as it was entered Queries greatly reduce the data retrieval time
64
Filter Feature Copyright Crespo Technology Services Group, Inc. 64 Display only the records that match your criteria Filter data based on the values in a column Filter by: Text for the text data type Number filters for the number data type Date filters for the date data type Multiple filters can be applied to a table at the same time.
65
Query Wizard Copyright Crespo Technology Services Group, Inc. 65 Select Query Wizard Select type of query Select query fields Request query detail Add title. Click Finish Query result shown
66
Query Types Copyright Crespo Technology Services Group, Inc. 66 Simple: Can select fields from multiple tables and queries Crosstab: Can perform simple calculations Find duplicates: Can find duplicate field values Find unmatched: Finds records in a table with no related records on another table
67
Query Design Context Tab Copyright Crespo Technology Services Group, Inc. 67 Query Design Results Query Type Query Setup Show/Hide
68
Query Object Views Copyright Crespo Technology Services Group, Inc. 68 Design View SQL View Datasheet View PivotTable View PivotChart View
69
Show Tables Dialog Box Copyright Crespo Technology Services Group, Inc. 69 The Show Tables dialog box is found on the Query Design Context Tab The user can select to view: Tables Queries Both
70
Create a Query Copyright Crespo Technology Services Group, Inc. 70 Class Exercise Create a query of students Create a query of books
71
Query Criteria Copyright Crespo Technology Services Group, Inc. 71 Search condition to retrieve specific information These are used to compare criteria value with values in the column Calculations can also be performed
72
Comparison Operators Copyright Crespo Technology Services Group, Inc. 72 Symbols used to compare two values When set in criterion establishes results after comparison The result is always a true or false
73
List of Comparison Operators Copyright Crespo Technology Services Group, Inc. 73 = : Equals < : Less than <= : Less than or equal to > : Greater than >= : Greater than or equal to <> : Not equal to Between And : Within a range Is Null : Null values
74
Conditional Operators Copyright Crespo Technology Services Group, Inc. 74 Test for the truth of a comparison The result is always a true or false Parenthesis can be used to change the order of evaluation
75
List of Conditional Operators Copyright Crespo Technology Services Group, Inc. 75 AND : True if both conditions are true Example: >2 AND <>10 OR : True if either condition is true Example: 100 NOT : True if the single instance is not true Example: Not Between 2 and 10
76
Create a Query Copyright Crespo Technology Services Group, Inc. 76 Class Exercise Create a query of students that have books out Create a query of books that are past due to be returned
77
Calculated Fields Copyright Crespo Technology Services Group, Inc. 77 Values come from calculations with other fields Are not entered by the user but are created when query runs The values may change if the expression is changed
78
Arithmetic Operators Copyright Crespo Technology Services Group, Inc. 78 Arithmetic Operator DescriptionExample +Additionvalue1 + value 2 -Subtractionvalue1 - value 2 *Multiplicationvalue1 * value 2 /Divisionvalue1 / value 2
79
Expressions Copyright Crespo Technology Services Group, Inc. 79 Values come from calculations with other fields Are not entered by the user but are created when query runs The values may change if the expression is changed
80
Expression Builder Copyright Crespo Technology Services Group, Inc. 80 Allows users to select objects and use operators and functions to build formulas These can be used in queries or reports
81
Property Sheet Pane Copyright Crespo Technology Services Group, Inc. 81 Allows users to set properties to objects These properties can be of Structure, appearance and behavior Features include Description, Format, Decimal Places, Input Mask, Caption and Mart Tags
82
Group by Functions Copyright Crespo Technology Services Group, Inc. 82 Perform calculations on a group of values Can be used with any number of values and result in a single value Aggregate functions are used to group records in all databases
83
Designing Forms Copyright Crespo Technology Services Group, Inc. 83
84
Designing Forms Copyright Crespo Technology Services Group, Inc. 84 Datasheet view Can be difficult to view large amounts data Searching can be time consuming Can lead to errors by misreading a value Access forms Allows to view and edit one record at a time Is easier to view
85
Form Views Copyright Crespo Technology Services Group, Inc. 85 ViewDescription DesignA static view that helps design a form. FormA dynamic view data within the developed form LayoutAn interactive and dynamic view that you can use to create a form
86
Form Sections Copyright Crespo Technology Services Group, Inc. 86 Perform calculations on a group of values Can be used with any number of values and result in a single value Aggregate functions are used to group records in all databases
87
Group by Functions Copyright Crespo Technology Services Group, Inc. 87 Header: Displays Title Detail: Displays fields Footer: Displays additional information
88
Form Creation Tools Copyright Crespo Technology Services Group, Inc. 88 Form Creation ToolDescription FormCreates a form with all fields in a table Form DesignHelps you create a form in Design view Split FormLets you view the form in Form view and Datasheet view simultaneously Multiple ItemsLets you view multiple records from the table in the form of a spreadsheet PivotChartHelps you create a form in PivotChart view Blank FormUse a blank form to build a form from scratch Form WizardA tool that helps you through the process of creating a form
89
Modifying the Design of a Form Copyright Crespo Technology Services Group, Inc. 89 Can be dome by modifying the TAB order Add, delete or modify controls Bound: Associated to a field in the table or query Unbound: Not associated with data Calculated: Displays data obtained by evaluating an expression
90
Generating Reports Copyright Crespo Technology Services Group, Inc. 90
91
Report Views Copyright Crespo Technology Services Group, Inc. 91 ViewDescription DesignAbility to add, modify or delete controls. Cannot view data. ReportView data without ability to make changes to controls LayoutView data and ability to make changes to controls Print PreviewCheck how the report will print
92
Report Sections Copyright Crespo Technology Services Group, Inc. 92 Header: Displays Title Detail: Displays fields Footer: Displays additional information
93
Report Creation Tool Copyright Crespo Technology Services Group, Inc. 93 ViewDescription ReportCreates a report with all the fields Blank ReportCreate a blank report from scratch Report DesignHelps you create a report in Design view Report WizardHelps create a report by following step-by-step instructions
94
Report Creation Wizard Copyright Crespo Technology Services Group, Inc. 94
95
Report Printing Copyright Crespo Technology Services Group, Inc. 95
Similar presentations
© 2024 SlidePlayer.com Inc.
All rights reserved.