Computed Values in Extra Queries

Previous Next

See Also

You may use extra queries to show the result of computations. Using this facility, you may display the number of computers of a particular model, for example. That is, use the extra query to compute a value for each visible record in a box.

To compute the number of tours that last a particular number of days, you may write the following query:

SELECT   COUNT(num_days) "Number of days"

FROM     FROM     schedtour_c, tour

RELATE   c "SUBJECT TO" h

As the query is performed once for each record in the box, you do not need a GROUP BY clause.

USoft Developer cannot retrieve a field prompt for this field from the repository. If you do not provide one yourself, it uses "COUNT(num_days)".