Once the user completes the qbe form the qbe engine

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: or all fields. The Find command cannot be used for creating an elaborate set "of criteria for complex queries. Furthermore, it can operate on only one table at a time, and the user cannot save a specified criteria for future use. Query Language For handling complex quieries, all database systems support a query language. Most of these query languages conform to the SQL standard. In SQL, the user has to specify the criteria for search along with the fields and table (or tables) with which to work with. The criteria for search can be built by using the relational operators (= [equal to], > [greater than], < [less that], and combinations of these operators) and the logical operators (AND, OR, and NOT). For example, to list out the names of all employees whose last name starts with the letter "S", who belong to "PUNE", and whose age is more than 40 years, the SQL query will look as follows: SELECT [LAST NAME], [FIRST NAME], [MIDDLE NAME] FROM Employee WHERE ([LAST NAME] = "S..") AND (CITY = "PUNE") AND [AGE > 40]) The keywords SELECT, FROM, and WHERE tell the SQL engine how to interpret each part of the query statement. The SELECT keyword tells SQL which fields are to be displayed for the records that match the criteria. The FROM keyword tells SQL which table(s) to work with. The WHERE keyword tells SQL the criteri for selecting the records (search criteria). The brackets [...] around some of the field names are needed in the above example because these field names contain spaces, and the brackets help the database to interpret each field name correctly. A query language can be easily learnt and used even by a non-programmer because the complexity of a query language statement is normally more or less of the same order as given in the above SQL statement. Furthermore, a query language uses only a few keywords which are easy to remember and use. In fact, SQL has only a few dozen or so basic keywords. Other advantages of using a query language are that a query statement can be used for creating an elaborate set of...
View Full Document

Ask a homework question - tutors are online