Some other query issues:

Slides:



Advertisements
Similar presentations
CC SQL Utilities.
Advertisements

Creating Forms in Microsoft Word Lunch and Learn: April 2, 2008.
© Paradigm Publishing, Inc Access 2010 Level 1 Unit 2Creating Forms and Reports Chapter 6Creating Reports and Mailing Labels.
Benchmark Series Microsoft Access 2010 Level 1
Database Features. Lists n An Excel worksheet can be used like a table in a relational database. n In Excel, such a table is called a list. n Each row.
Microsoft Office 2007 Access Integration Feature Sharing Data Among Applications.
SUNY Morrisville-Norwich Campus- Week 7 CITA 130 Advanced Computer Applications II Spring 2005 Prof. Tom Smith.
1 Computing for Todays Lecture 17 Yumei Huo Fall 2006.
XP New Perspectives on Microsoft Office Excel 2003, Second Edition- Tutorial 11 1 Microsoft Office Excel 2003 Tutorial 11 – Importing Data Into Excel.
Overview Importing text files Creating Forms Creating Reports.
Chapter 2 Querying a Database
Access Presentation 3 By: Rasagnya Waghray Ali Murtuza.
Microsoft Access 2010 Chapter 7 Using SQL.
Access Tutorial 8 Sharing, Integrating, and Analyzing Data
Chapter 2 Querying a Database
Introduction to Access By Mary Ann Chaney and Alicia Harkleroad.
Importing Data Text Data Parsing Scrubbing Data June 21, 2012.
Chapter 2 Querying a Database MICROSOFT ACCESS 2010.
Database Applications – Microsoft Access Lesson 9 Designing Special Queries Updated 4/11.
Database Applications – Microsoft Access Lesson 9 Designing Special Queries.
With Microsoft Office 2007 Introductory© 2008 Pearson Prentice Hall1 PowerPoint Presentation to Accompany GO! with Microsoft ® Office 2007 Introductory.
Chapter 10: Working with Large Data Spreadsheet-Based Decision Support Systems Prof. Name Position (123) University Name.
Chapter Extension 6 Using Excel and Access Together.
Chapter 1 Databases and Database Objects: An Introduction
Exam Review – Queries & MORE! Access SimNet Exam Access Case Exam Final Exam.
Analysing Data with Excel Importing Data from a Text File To import data from a text file: 1.Start Excel. 2.Click File, click New, click Workbook,
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 Integrating Microsoft Office 2003 Tutorial 2 – Integrating Word, Excel, and Access.
XP New Perspectives on Integrating Microsoft Office XP Tutorial 2 1 Integrating Microsoft Office XP Tutorial 2 – Integrating Word, Excel, and Access.
Microsoft Office 2007 Access Chapter 2 Querying a Database.
Office Management Tools II Ms Saima Gul. Office Management Tools II Ms Saima Gul.
® Microsoft Access 2010 Tutorial 3 Maintaining and Querying a Database.
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.
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.
MODULE 7 Microsoft Access 2010 Chapter 1: Working with Databases Chapter 2: Using Forms and Tables Chapter 3: Working with Queries and Reports 1© Paradigm.
Chapter 6 Creating, Sorting, and Querying a Table
How do I export the Address Book to Excel? The first step is to go to "Address Book Report" under Admin Only menu Choose the fields you want. note that.
You can sort Access data so you can view records in the order you want to view them, and you can filter data so you only see the records you want to see.
1 Lesson 18 Managing and Reporting Database Information Computer Literacy BASICS: A Comprehensive Guide to IC 3, 3 rd Edition Morrison / Wells.
DAY 16: MICROSOFT ACCESS – CHAPTER 2 Madhuri Siddula October 8, 2015.
XP New Perspectives on Integrating Microsoft Office 2003 Tutorial 2 1 Integrating Microsoft Office 2003 Tutorial 2 – Integrating Word, Excel, and Access.
Importing Data to Excel. Suppose you have a delimited* text file and you need to bring it into Excel. Follow these steps… *Delimited means text separated.
Chapter 10: Working with Large Data Spreadsheet-Based Decision Support Systems Prof. Name Position (123) University Name.
Microsoft Access By Ritesh Sharma. Introduction Microsoft Access is a desktop database program that enables you to enter, store, analyze,and present data.For.
McGraw-Hill/Irwin © 2008 The McGraw-Hill Companies, All Rights Reserved Plug-In T7: Problem Solving Using Access 2007 Business Driven Technology.
ACCESS PROJECT TWO. PROJECT ONE In project one you: -Created Tables -Created Forms -Created Reports In this project you will learn about queries. Databases.
Creating Salary Notices Using Mail Merge
Computer Fundamentals
Lesson 23 Managing and Reporting Database Information
Queries.
Access Chapter 2 Querying a Database.
Plug-In T7: Problem Solving Using Access 2007
Larry Reaves October 9, 2013 Day 16: Access Chapter 2 Larry Reaves October 9, 2013.
European Computer Driving Licence
Exploring Microsoft® Access® 2016 Series Editor Mary Anne Poatsy
MODULE 7 Microsoft Access 2010
Chapter 9 Lesson 2 Notes.
Access Tutorial 8 Sharing, Integrating, and Analyzing Data
Click ‘browse’ to search your device for
Access Tutorial 5 Creating Advanced Queries and Enhancing Table Design
Navya Thum January 30, 2013 Day 5: MICROSOFT EXCEL Navya Thum January 30, 2013.
Chapter 1 Databases and Database Objects: An Introduction
Access: Queries IV Participation Project
Lesson 24 Managing and Reporting Database Information
Chapter 18 Finalizing a Database.
Using Complex Formulas, Functions, and Tables
Shelly Cashman: Microsoft Access 2016
Tutorial 8 Sharing, Integrating, and Analyzing Data
Microsoft Office Illustrated Fundamentals
Presentation transcript:

Some other query issues: To sort in a query place either “ascending” or “descending” in the sort line of the query in the appropriate field.

The Like condition: Wildcards The Like condition allows you to create a Query condition which matches certain patterns. There are 3 wildcard characters. * Arbitrary number of characters ? A single character # A single numeric digit 1) Given a list of names: Which names has an a in the second character? Like “?a*” matches Tammy Jane but not John 2) Given a list of names: Which names starts with an m? Like “m*” matches Moses , Manny, Mary, Max

Given a list of names: Which name has a “k” in it? Like “*k*” matches Lucky Knut Match a name: Like "Smith“ Match a name beginning with “Sm”: Like "Sm*“ Match a string with a letter followed by 3 digits: Like “?###”

Do you need to isolate records where a field has not been filled in? Use: is null in the criteria line To use dates put # around the date: >#26/11/2009# and <#31/12/2009# The between operator (it is inclusive) BETWEEN #6/15/2009# AND #8/15/2009# BETWEEN 10.0 AND 15.0

Grouping Queries Suppose you have a table as below with names and value . You wish to make a query which gives the sum( or AVG or COUNT) of the values.

Create a query with the two fields on the table. Select the two fields. Pick the design menu in the menu bar. Change the query type to a grouping query by clicking the Sigma symbol in the tool bar. You will notice that a “total line” appears below and each field has “group by” in it. Replace the “group by” in the field you wish to sum by “sum” (or if you wish by AVG or COUNT) Save the query and run it.

So following the steps. If we start with the table: The query looks like:

The result is:

Make Table Queries “Select Queries” or the regular queries are self contained objects but the result of a query looks like a table. If you wish to make the results of a query into a table we use a : Make table Query” This type of query is made from a “select” query. So we need to create a select query on some table in the usual way.

4.Run the query: BUT IT STILL MAY NOT WORK SO SEE NEXT SLIDE Design your select query and run it to make sure it has the desired look. Open your query in design view. Click on Make Table and name the table in the dialogue box that appears. 4.Run the query: BUT IT STILL MAY NOT WORK SO SEE NEXT SLIDE

If the new table does not appear, You may see a warning: Security warning: certain content in this database has been disabled. Click on the options box beside it and click on the “enable this content” and then run the query. You will then see the result of the query in your new named table.

Importing and exporting in Access Access allows you to bring in data from other formats and export data to other formats. e.g. Import a text file into an Access table e.g export an access table to a spreadsheet.

e.g. Importing a text file. Example comma delimited text file. Data is delimited by commas. Problem if you have commas as part of the text. A0001,Banks,Rob,555-2232,23 Elm St.,Ottawa,ON,K3O 4J2 A0003,Dover,Ben,378-2321,565 Oak Ave.,Nepean,ON,H6J 9J9 A4339,Dup,Stan,923-4348,232 Lois Lane,Toronto,ON,H3J 3J3 B0023,Jass,Hugh,789-0988,67 Pine Cres.,Montreal,QU,J8J 0L9 B0024,Bird,Earl E.,890-1232,809 Birch Ave.,Toronto,ON,K9D 8E8 C0012,Pull,Sam,892-3323,102 Lois Lane,Toronto,ON,K9D 8E8 C0054,Class,Jim,892-5673,63 Moodie Drive,Nepean,ON,K1D 3J4

Example: comma and quote delimited text file Example: comma and quote delimited text file. Data is delimited by commas and quotes. "A0001","Banks","Rob","555-2232","23 Elm St.","Ottawa","ON","K3O 4J2" "A0003","Dover","Ben","378-2321","565 Oak Ave.","Nepean","ON","H6J 9J9" "A4339","Dup","Stan","923-4348","232 Lois Lane","Toronto","ON","H3J 3J3" "B0023","Jass","Hugh","789-0988","67 Pine Cres.","Montreal","QU","J8J 0L9" "B0024","Bird","Earl E.","890-1232","809 Birch Ave.","Toronto","ON","K9D 8E8" "C0012","Pull","Sam","892-3323","102 Lois Lane","Toronto","ON","K9D 8E8" "C0054","Class","Jim","892-5673","63 Moodie Drive","Nepean","ON","K1D 3J4"

To import: In the external data tab Under the “import” group import “text file” and follow the wizard. You will have to name the fields and specify the types but the wizard will do pretty well.

To export data: For example turning an Access table into an excel spreadsheet. In the external data tab Under the “export” group export “excel” and follow the wizard. You have to specify the name and destination and you will probably have to adjust the heading labels in the resulting spreadsheet.