8. Generating Frames from Predefined Templates : The mastdetl Templates : The simple_field Template : How You Can Perform a Query
 
Share this page                  
How You Can Perform a Query
When the Query is selected from the Form menu of a simple field frame, the Query dialog appears. On this dialog, you can perform queries based on data entered into one or more entry fields.
The following features are available:
Reading a Query
To read a saved query, click File, Read from File. This displays a standard File Selection dialog from which you can select a file.
Defining a Query
You enter data into the desired fields to define your query. Click Query, Clear to clear all fields on the form.
You can save the current query to a file by clicking File, Write to File. This also displays a standard File Selection dialog, allowing you to select the name and location of the file.
Running a Query
To perform the query, click Run (or click Query, Run).
Accessing Previous Queries
To navigate through previously run queries, click Query, Previous and Query, Next. As you step through each query, the matrix of fields is populated with the associated query data.
Viewing the SQL Commands
You can view the SQL statements and commands that will be executed when the current query is run, by clicking Query, View SQL.
Sorting Query Data
By clicking Query, Sort, you can select the sort order of the rows that are returned from the query. (This is the same sort order used for the simple field frame, accessed by clicking Form, Sort.)
For more information, see How You Can Sort Data in a Frame.