query task

11
Query Task • In this lesson you will be creating two queries – a simple query – an AND query • You will be creating one to do the following: Super heroes that can fly Super heroes who are tall AND famous

Upload: miriam

Post on 24-Feb-2016

29 views

Category:

Documents


0 download

DESCRIPTION

Query Task. In this lesson you will be creating two queries a simple query an AND query You will be creating one to do the following: Super heroes that can fly Super heroes who are tall AND famous. Instructions on how to create a simple query. Select ‘ Create ’ - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: Query Task

Query Task

• In this lesson you will be creating two queries– a simple query– an AND query

• You will be creating one to do the following:– Super heroes that can fly– Super heroes who are tall AND famous

Page 2: Query Task

Instructions on how to create a simple query

• Select ‘Create’• Choose the ‘Query Design’ icon• Click on the add button to add

the table ( characters) and then click on the close button

Page 3: Query Task

How to add your table and select fields

Double click on each field name to add it to the bottom

Page 4: Query Task

Simple Query- Super heroes who can fly

• A simple query is where we are searching for records that match only one criteria.

• Under the Super Power, in the criteria row, enter ‘flight’

Page 5: Query Task

Simple Query- Super heroes who can fly

• Next you need to save your query.• Right click on the Tab and select Save.• Save this query as ‘Superheroes who can fly’

Page 6: Query Task

And Query-Superheroes who are tall and famous

• Check your query works by opening it.• If it doesn’t work, you can check your query by right

clicking on the query and opening it in Design View

Page 7: Query Task

And Query-Superheroes who are tall and famous

• An AND query is where we are searching for records that match two or more criteria like the example shown below.

• If you do correctly the design view of the query will look similar to this

Save this query as –tall and famous heroes

Page 8: Query Task

Extra Information

• The next few slides will have some extra information on Queries

Extension• Can you create your own query?

Page 9: Query Task

Logical Query

• These types of queries use the following symbols

• Can be used on the following types of data– Number fields– Currency Fields– Date/Time fields

< Less than ( before)

> More than (after)

<= Less than or equal to

>= More than or equal to

BETWEEN __ AND __ Between two values

Page 10: Query Task

Example of a logical query

Pocket money is Less than

£10

Page 11: Query Task

Parameter Query• A query related to particular query that can be

used over and over again• It comes up with a prompt box for you to enter

criteria every time it is run• E.g.

– Find all the people with a certain special talent