12. Report-Writer Statements : Report Setup Statements : .Query Statement for QUEL Users
Share this page                  
.Query Statement for QUEL Users
This statement specifies a QUEL query to be used to generate data for a report.
The .query statement for QUEL has the following format:
retrieve [unique] (target_list) [where qual]
    [sort by | order by...] sort-list
The parameters for the QUEL .query statement are as follows:
Valid QUEL range statements used to identify the tables used in the query.
A valid QUEL target list that creates data for the report. The retrieve into form of the retrieve statement is not used.
A valid QUEL qualification to a query.
A valid set of sort columns according to the rules for constructing QUEL retrieve statements. Note that you cannot use both a .sort statement and a sort by or order by clause in the same report specification.