Improving Queries. Objectives Create multitable queriesCreate multitable queries Apply sorts and view SQLApply sorts and view SQL Develop AND criteriaDevelop.

Slides:



Advertisements
Similar presentations
Working with Tables 1 of 5. Working with Tables 2 of 5.
Advertisements

Microsoft Office Illustrated Creating Multiple Table Queries.
Microsoft Office Illustrated Building and Using Queries.
Pasewark & Pasewark Microsoft Office XP: Introductory Course 1 INTRODUCTORY MICROSOFT ACCESS Lesson 4 – Finding and Ordering Data.
The University of Akron Dept of Business Technology Computer Information Systems The Relational Model: Query-By-Example (QBE) 2440: 180 Database Concepts.
Microsoft Office 2007 Access Chapter 2 Querying a Database.
Office 2003 Introductory Concepts and Techniques M i c r o s o f t Access Project 2 Querying a Database Using the Select Query Window.
Access Tutorial 3 Maintaining and Querying a Database
XP New Perspectives on Microsoft Office Access 2003, Second Edition- Tutorial 3 1 Microsoft Office Access 2003 Tutorial 3 – Querying a Database.
XP Chapter 3 Succeeding in Business with Microsoft Office Access 2003: A Problem-Solving Approach 1 Analyzing Data For Effective Decision Making.
Querying a Database Using the Select Query Window
Querying a Database Microsoft Office Access 2003.
Tutorial 5: Working with Excel Tables, PivotTables, and PivotCharts
Chapter 2 Querying a Database
A lesson approach © 2011 The McGraw-Hill Companies, Inc. All rights reserved. a lesson approach Microsoft® Access 2010 © 2011 The McGraw-Hill Companies,
1 Access Lesson 3 Creating Queries Microsoft Office 2010 Introductory Pasewark & Pasewark.
1 Access Lesson 3 Creating Queries Microsoft Office 2010 Introductory.
Maintaining and Querying a Database Microsoft Access 2010.
1 Microsoft Access 2002 Tutorial 3 – Querying a Database.
Chapter 2 Querying a Database MICROSOFT ACCESS 2010.
Lesson 31: Querying a Database. 2 Learning Objectives After studying this lesson, you will be able to:  Create, save, and run select queries  Design.
You can use a query to view a subset of your data or to answer questions about your data. For example, if you want to view a list of student names and.
Copyright © 2010 Pearson Education, Inc. Publishing as Prentice Hall1 Exploring Microsoft Office Access Committed to Shaping the Next Generation.
With Microsoft Office 2007 Introductory© 2008 Pearson Prentice Hall1 PowerPoint Presentation to Accompany GO! with Microsoft ® Office 2007 Introductory.
Copyright 2007, Paradigm Publishing Inc. ACCESS 2007 Chapter 4 BACKNEXTEND 4-1 LINKS TO OBJECTIVES Query Design Query Criteria Modify a Query Using OR.
1 Chapter 7 Query-By-Example by Monica Chan CS157B Professor Lee.
Building and Using Queries. Objectives Use the Query WizardUse the Query Wizard Work with data in a queryWork with data in a query Use Query Design ViewUse.
Microsoft Access 2010 Building and Using Queries.
Analyzing Data For Effective Decision Making Chapter 3.
© 2008 The McGraw-Hill Companies, Inc. All rights reserved. ACCESS 2007 M I C R O S O F T ® THE PROFESSIONAL APPROACH S E R I E S Lesson 6 – Designing.
® Microsoft Office 2010 Access Tutorial 3 Maintaining and Querying a Database.
Microsoft Office 2007 Access Chapter 2 Querying a Database.
Examining data using Microsoft Access Queries Using Criteria and Calculations SESSION 3.2 This section covers specifying an exact match condition in a.
® Microsoft Office 2010 Access Tutorial 3 Maintaining and Querying a Database.
Microsoft Access Illustrated Unit B: Building and Using Queries.
Microsoft Office XP Illustrated Introductory, Enhanced Reports Using.
XP Chapter 3 Succeeding in Business with Microsoft Office Access 2003: A Problem-Solving Approach 1 Analyzing Data For Effective Decision Making Chapter.
Copyright 2008 McGraw-Hill Ryerson 1 TECHNOLOGY PLUG-IN T7 PROBLEM SOLVING USING ACCESS.
® Microsoft Access 2010 Tutorial 3 Maintaining and Querying a Database.
COMPREHENSIVE Access Tutorial 3 Maintaining and Querying a Database.
Microsoft Office XP Illustrated Introductory, Enhanced Tables and Queries Using.
Course ILT Forms and queries Unit objectives Create forms by using AutoForm and the Form Wizard, and add or modify form headers and footers Open and enter.
® Microsoft Office 2013 Access Maintaining and Querying a Database.
ACCESS Part 2. OBJECTIVE  Use the Query Wizard.  Work with data in a query.  Use Query Design View.  Sort and find data.  Filter data Apply AND criteria.
Pasewark & Pasewark 1 Access Lesson 3 Creating Queries Microsoft Office 2007: Introductory.
McGraw-Hill/Irwin © 2008 The McGraw-Hill Companies, All Rights Reserved Plug-In T7: Problem Solving Using Access 2007 Business Driven Technology.
Database Applications – Microsoft Access Lesson 4 Working with Queries 36 Slides in Presentation.
Reports and Queries Chapter 3 – Access text Reports – Page Queries – Page
Microsoft Office 2010 for Medical Professionals - Illustrated Access 2010 Unit B: Building and Using Queries.
XP. Objectives Sort data and filter data Summarize an Excel table Insert subtotals into a range of data Outline buttons to show or hide details Create.
Microsoft Office 2013: In Practice Chapter 3 Creating and Using Queries Copyright © 2014 by The McGraw-Hill Companies, Inc. All rights reserved.McGraw-Hill/Irwin.
T7-1 LEARNING OUTCOMES – ACCESS PROBLEM SOLVING 1.Describe the process of using the Simple Query Wizard using Access 2.Describe the process of using the.
Pasewark & Pasewark Microsoft Office 2003: Introductory 1 INTRODUCTORY MICROSOFT ACCESS Lesson 4 – Finding and Ordering Data.
XP New Perspectives on Microsoft Office Access 2003, Second Edition- Tutorial 5 1 Microsoft Office Access 2003 Tutorial 5 – Enhancing a Table’s Design.
MSOffice Access Microsoft® Office 2010: Illustrated Introductory 1 Part 2 ® Building Queries.
Lesson 4: Querying a Database. 2 Learning Objectives After studying this lesson, you will be able to:  Create, save, and run select queries  Set query.
McGraw-Hill/Irwin © 2008 The McGraw-Hill Companies, All Rights Reserved Plug-In T7: Problem Solving Using Access 2007 Business Driven Technology.
Microsoft Office Illustrated Introductory, Windows Vista Edition
Access Tutorial 3 Maintaining and Querying a Database
Access Chapter 2 Querying a Database.
Plug-In T7: Problem Solving Using Access 2007
Querying a Database Using the Select Query Window
Microsoft Access 2003 Illustrated Complete
Building and Using Queries
Microsoft Office Access 2003
Microsoft Office Access 2003
Microsoft Office Access 2003
Microsoft Office Illustrated Introductory, Windows XP Edition
Assignment 3 Querying and Maintaining a Database
New Perspectives on Microsoft
Presentation transcript:

Improving Queries

Objectives Create multitable queriesCreate multitable queries Apply sorts and view SQLApply sorts and view SQL Develop AND criteriaDevelop AND criteria Develop OR criteriaDevelop OR criteria Microsoft Office 2013-Illustrated2

Objectives Create calculated fieldsCreate calculated fields Build summary queriesBuild summary queries Build crosstab queriesBuild crosstab queries Create a report on a queryCreate a report on a query Microsoft Office 2013-Illustrated3

Creating Multitable Queries A select query selects fields from related tables and displays records in a datasheetA select query selects fields from related tables and displays records in a datasheet Query Design View gives you more options for selecting and presenting information.Query Design View gives you more options for selecting and presenting information. When you open (or run) a query, the fields and records that you selected for the query are presented in Query Datasheet View.When you open (or run) a query, the fields and records that you selected for the query are presented in Query Datasheet View. 4Microsoft Office 2013-Illustrated

Creating Multitable Queries 5Microsoft Office 2013-Illustrated

Applying Sorts and Viewing SQL Sorting refers to reordering records in either ascending or descending order based on the values in a field.Sorting refers to reordering records in either ascending or descending order based on the values in a field. You can specify more than one sort field in Query Design View.You can specify more than one sort field in Query Design View. Sort orders are evaluated from left to right, meaning that the sort field on the far left is the primary sort field.Sort orders are evaluated from left to right, meaning that the sort field on the far left is the primary sort field. Sort orders defined in Query Design View are saved with the query object. Sort orders defined in Query Design View are saved with the query object. 6Microsoft Office 2013-Illustrated

Applying Sorts and Viewing SQL 7Microsoft Office 2013-Illustrated

Developing AND Criteria Criteria are tests, or limiting conditions, that must be true for the record to be selected for a datasheet.Criteria are tests, or limiting conditions, that must be true for the record to be selected for a datasheet. To create AND criteria, which means the query selects a record only if all criteria are true, enter two or more criteria on the same Criteria row of the query design grid.To create AND criteria, which means the query selects a record only if all criteria are true, enter two or more criteria on the same Criteria row of the query design grid. To create AND criteria for the same field, enter the two criteria in the same Criteria cell separated by the AND operator.To create AND criteria for the same field, enter the two criteria in the same Criteria cell separated by the AND operator. 8Microsoft Office 2013-Illustrated

Common Comparison Operators 9Microsoft Office 2013-Illustrated

Developing OR Criteria OR criteria expand the number of records in the datasheet because a record needs to be true for only one of the criteria.OR criteria expand the number of records in the datasheet because a record needs to be true for only one of the criteria. You enter OR criteria in the query design grid on different criteria rows.You enter OR criteria in the query design grid on different criteria rows. 10Microsoft Office 2013-Illustrated

Developing OR Criteria 11Microsoft Office 2013-Illustrated

Creating Calculated Fields A calculated field is a field of data that can be created based on the values of other fields.A calculated field is a field of data that can be created based on the values of other fields. An expression is a combination of field names, operators (such as +, –, /, and *), and functions that result in a single value.An expression is a combination of field names, operators (such as +, –, /, and *), and functions that result in a single value. A function is a predefined formula that returns a value such as a subtotal, count, or the current date.A function is a predefined formula that returns a value such as a subtotal, count, or the current date. 12Microsoft Office 2013-Illustrated

Creating Calculated Fields 13Microsoft Office 2013-Illustrated

Creating Calculated Fields 14Microsoft Office 2013-Illustrated

Building Summary Queries A summary query calculates statistics about groups of records.A summary query calculates statistics about groups of records. To create a summary query, you add the Total row to the query design grid to specify how you want to group and calculate the statistics using aggregate functions.To create a summary query, you add the Total row to the query design grid to specify how you want to group and calculate the statistics using aggregate functions. Aggregate functions calculate a statistic such as a subtotal, count, or average on a field in a group of records.Aggregate functions calculate a statistic such as a subtotal, count, or average on a field in a group of records. 15Microsoft Office 2013-Illustrated

Building Summary Queries 16Microsoft Office 2013-Illustrated

Building Summary Queries 17Microsoft Office 2013-Illustrated

Building Crosstab Queries A crosstab query subtotals one field by grouping records using two other fields that are placed in the column heading and row heading positions.A crosstab query subtotals one field by grouping records using two other fields that are placed in the column heading and row heading positions. You can use the Crosstab Query Wizard to guide you through the steps of creating a crosstab query, or you can build the crosstab query from scratch using Query Design View.You can use the Crosstab Query Wizard to guide you through the steps of creating a crosstab query, or you can build the crosstab query from scratch using Query Design View. 18Microsoft Office 2013-Illustrated

Building Crosstab Queries 19Microsoft Office 2013-Illustrated

Create a Report on a Query When you want a more professional printout of the information that can be provided by a query datasheet, you use a report object.When you want a more professional printout of the information that can be provided by a query datasheet, you use a report object. When you base a report on a query the query name is identified in the Record Source property of the report.When you base a report on a query the query name is identified in the Record Source property of the report. 20Microsoft Office 2013-Illustrated

Create a Report on a Query 21Microsoft Office 2013-Illustrated