Class 10 Computer Science Note

QUERYING DATABASE

Microsoft Access Query

Query is a way of extracting information from a database, usually by using certain criteria or requesting certain data. It is request for database records that fit specified criteria.

 

Uses of query

i. A query can count the amount of records that meet the certain criteria.

ii. It can also be used to extract data to a separate table or delete data, change data and many other things.

 

Dynaset 

A dynaset is a set of data that is dynamically linked back to the database. Instead of having the query result stored in a temporary table, where the data cannot be updated directly by the user, the dynaset allows the user to view and update the data contained in the dynaset.

 

Types of queries

a. Select query = It is a query in which the relevant data from a table is selected and displayed. It allows the user to retrieve data from one or more tables and displays the results in a datasheet where the user can update the record.

b. Parameter queries = It is a query that when run displays its own dialog box prompting the user for information, such as criteria for retrieving records or value the user want to insert in a field.

c. Crosstab queries = A query that calculates a sum, average, count, or other type of total for data that is grouped by the two types of information is known as crosstab queries.

d. Action queries = A query which performs an action with the records /fields selected by the query. Action queries includes delete, Append, update and make table queries.

 

Differences between filter and Select query

Filter

Query

A filter cannot be saved as separate object.

A query can be saved as separate object.

A filter cannot be used for displaying the records of more than related table at once.

A query can be used for displaying the records of more than related table at once.

A filter cannot be used for performing calculation on values of numeric fields.

A query can be used for performing calculation on values of numeric fields.

 

 

Queries are used

a. Update data, delete records or append new records to a table.

b. Create a new table with records from one or more tables.

c. view data form multiple tables sorted in a specific order.

d. Find and display duplicate or unmatched records.


Go Top