Operation Manual
Using the Wizard to create a query
Queries created by the wizard provide a list or lists of information based upon what one wants to
know. It is possible to obtain a single answer or multiple answers, depending upon the
circumstances.
In the main database window (Figure 199), click the Queries icon in the Databases section, then in
the Tasks section, click Use Wizard to Create Query. The Query Wizard window opens (Figure
235). The information we want is what albums are by a certain musical group or individual (the
album’s author). We can include when each album was bought.
Note
When working with a query, more than one table can be used. Since different tables
may contain the same field names, the format for naming fields in a query is Table
name.field name, with a period (.) between the table name and the field name. For
example, the Lunch field of the Vacation table used in a query has the name
Vacation.Lunch.
Step 1: Select the fields.
1) Select the CD-Collection table from the drop down list of tables.
2) Select fields from the CD-Collection table in the Available fields list.
a) Click Artist, and use the > button to move it to the Fields in the Query list.
b) Move the AlbumTitle and DatePurchased fields in the same manner.
c) Click Next.
Tip
To change the order of the fields, select the field you want to move and click the up
or down arrow.
Figure 235: First page of the Query Wizard
Step 2: Select the sorting order.
Up to four fields can be used to sort the information of our query. A little simple logic helps at this
point. Which field is most important?
246 | Getting Started with LibreOffice 4.0