logo


55.1.4 Summary: Input Form: Master Query page


 

Summary: Input Form: Master Query page

Except for Place Holders, this area behaves in a very similar manner to the Query area as described in “Reports: Query Store” on page 427.

Function of the Master Query page

The Master Query area reduces the workload for your Report by establishing Sets of records that may be used many times by a later Slave Query.

Any Set of records that will be used multiple times on the Reports should be evaluated here.

The Master Query area is evaluated once right at the start of Report execution. This means any Sets established here will be available to all other Slave Queries on the Report.

You do not necessarily need to define anything in the Master Query area - in this case all Queries will be performed by the Slave Queries. This may be appropriate if there is no common Query required by the Slave Queries.

Queries belong to the Report

We try to make STATIC elements reusable within the database. However, any Query defined here will be saved for exclusively for use within the Report. It will not be available in the Query Store area. If you want to make your Query available for use in other Reports or Queries then you can of course export the Master Query into a document and then Import it into another Query area. Or, alternatively, you can load a Query from the Query Store area into the Master Query area of the Report.

Sharing of Queries between Reports

Queries contain Sets and Place Holders. Sharing of Queries between and within Reports could cause problems, if a Set or Place Holder happens to have the same name as one already defined in the Report. In order to avoid this, the Report area has a sophisticated tracking system that automatically renumbers any Sets or Place Holder so that they do not clash.

Place Holders

The Query command is the ONLY command in the Master and Slave Query area for which you can define a Place Holder. This allows you to create a Query that could look like this:

QUERY [ICURecord] AND [ICURecord]Adm_Date >= <ICUAdmitDate_3>

Notice the Placeholder <ICUAdmitDate_3> at the end of the line.

All placeholders are bracketed by the < and > sign. Use the Set to be Place Holder Button and Clear Place Holder Button to control the setting of the Place Holder.

At execution time the placeholder is replaced by an actual value derived from the Place Holder page. If you have a Query as defined above then the Place Holder page may be as follows:

 

Summary: Input Form: Place Holder Page: Detail

When the Report executes, the <ICUAdmitDate_3> will be replaced by 01/07/1999 for the first run and 01/07/2000 for the subsequent run. See “Summary: Input Form: Place Holders page” on page 405 for more details.

We have not given you the option of setting Place Holders for the Query By Formula command. It was deemed too problematic. There is less control over the precise contents of a formula. This would lead to frustrating errors which would be very difficult to track down.



Harrowex Pty Ltd
http://www.hxmedical.com
Voice:+ 61 4 27 344 279
Fax: +61 3 52 439 019
static@hxmedical.com