Chapter 4-1Chapter 4: Organizing and Manipulating the Data in Databases Introduction Creating Database Tables in Microsoft Access Entering Data In Database Tables Extracting Data From D
Trang 1Chapter 4-1
Chapter 4:
Organizing and Manipulating the Data in
Databases
Introduction
Creating Database Tables in Microsoft Access
Entering Data In Database Tables
Extracting Data From Databases: Data Manipulation Languages
Recent Database Advances and Data Warehouses
Trang 2Chapter 4-2
Creating Database Tables in Microsoft Access
Database Management Systems
An Introduction to Microsoft Access
Creating Database Tables
Creating Relationships
Trang 3Chapter 4-3
Trang 4Chapter 4-4
Introduction to Microsoft
Access
A popular relational database
Used by many businesses and individuals
Used for small database applications
Trang 5Chapter 4-5
Microsoft Access – Opening
Screen
Trang 6Chapter 4-6
Creating Database Tables –
Defining Record Format
Field Name
Names assigned to the data fields
Data Type
Specified for each data field
Identifies how to store the data – field properties
Description
Optional field
Defines record structures
Trang 7Chapter 4-7
Creating Database Tables –
Opening Screen
Trang 8Chapter 4-8
Creating Database Tables –
Record Format
Trang 9Chapter 4-9
Creating Relationships
Purpose
Link tables together
Enable users to create multi-table reports
Steps in Creating Relationships
Select tables
Link the tables
Trang 10Chapter 4-10
Creating Database Relationships – Linking Tables
Trang 11Chapter 4-11
Creating Relationships –
Multitable Relationships
Trang 12Chapter 4-12
Creating Records
Utilize datasheet view to input data
Trang 13Chapter 4-13
Ensuring Valid and Accurate
Data Entry
Data Definition Language (DDL)
Enables users to define record structure
Define individual fields of each record
Trang 14Chapter 4-14
Tools for Data Validation
Proper Data Types for Fields
Trang 15Chapter 4-15
Tools for Data Validation
Trang 16Chapter 4-16
Drop-Down List Example
Trang 17Chapter 4-17
Validation Rule Example
Trang 18Chapter 4-18
Creating Referential Integrity
Trang 19Chapter 4-19
All of the following are examples of DBMSs except:
Trang 20Chapter 4-20
All of the following are examples of DBMSs except:
Trang 21Chapter 4-21
An example of a validation rule is:
A An input value must be an integer
B An input value must also have a default value
C An input value must be between 0 and 40
D You cannot delete parent records that have child records associated with them
Study Break #2
Trang 22Chapter 4-22
An example of a validation rule is:
A An input value must be an integer
B An input value must also have a default value
C An input value must be between 0 and 40
D You cannot delete parent records that have child records associated with them
Study Break #2 - Answer
Trang 23Chapter 4-23
Tips for Creating Database Tables and Records
Design first
Create tables and records last
Name tables systematically
Use conventional tbl prefixes
Use mnemonic names for data fields
Assign correct data types to data fields
Trang 24Chapter 4-24
Tips for Creating Database Tables and Records
Data fields that link tables must be the same data type
Limit the size of text data fields to reasonable lengths
Use input masks
Trang 25Chapter 4-25
Extracting Data From
Databases
Schema
All information in a database
All relationships of the tables
Map of entire database
Subschema
Subset of the schema
Trang 26Chapter 4-26
Creating Select Queries
Trang 27Chapter 4-27
Query Example
Trang 28Chapter 4-28
Creating Select Queries
One-Table Select Queries
Creates a dynaset
Based on:
Criteria determining which records to include
Criteria determining which fields to include from
those records
Single or Multiple Criteria
Trang 29Chapter 4-29
Select Query Example
Trang 30Chapter 4-30
Multi-Table Select Query
Example
Trang 31Chapter 4-31
Multi-Table Select Query
Example
Trang 32Chapter 4-32
Creating Action Queries
Trang 33Chapter 4-33
Query Wizard Queries
Simple query Wizard
Crosstab queries
Find-Duplicates queries
Find-unmatched queries
Trang 34Chapter 4-34
Query Wizard Screen
Trang 35Chapter 4-35
Guidelines for Creating
Queries
Spell accurately and be case sensitive
Specify AND and OR operations correctly
Tables must be joined properly
Name queries systematically
Choose data fields selectively
Trang 36Chapter 4-36
Extracting Data From
Databases
Structured Query Language (SQL)
Example of SQL Instructions
Trang 37Chapter 4-37
Extracting Data From
Databases
Online Analytical Processing (OLAP)
Complex, multidimensional data analysis
Pivot tables
Data Mining
Utilize a set of data analysis and statistical tools
Identify relationships, patterns, or trends
Trang 38Chapter 4-38
Cloud Computing
Form of Internet-based Computing
Software provided through the Internet
Processing occurs on a Web of computers
Expands IT capabilities
Database-As-A-Service (DAAS)
Outsourcing of databases
Backup Services
Trang 39Chapter 4-39
Span longer timeframe than transaction systems
Optimized data relationships
Trang 40Chapter 4-40
All of the following are examples of action queries except:
Trang 41Chapter 4-41
All of the following are examples of action queries except:
A Update query
B Append query
C Delete query
D Find missing data query
Study Break #3 - Answer
Trang 42Chapter 4-42
SQL is an example of:
A A tool to perform online analytical processing
B A database management system
C A query language
D A multimedia database
Study Break #4
Trang 43Chapter 4-43
SQL is an example of:
A A tool to perform online analytical processing
B A database management system
C A query language
D A multimedia database
Study Break #4 - Answer
Trang 44Chapter 4-44
Copyright
Copyright 2012 John Wiley & Sons, Inc All rights reserved
Reproduction or translation of this work beyond that permitted in
Section 117 of the 1976 United States Copyright Act without the
express written permission of the copyright owner is unlawful
Request for further information should be addressed to the
Permissions Department, John Wiley & Sons, Inc The purchaser
may make backup copies for his/her own use only and not for
distribution or resale The Publisher assumes no responsibility for errors, omissions, or damages, caused by the use of these programs or from the use of the information contained herein.
Trang 45Chapter 4-45
Chapter 4