'Query Designer' is used primarily for amending existing Report Queries. It may also be used for creation of new Reports (although it is recommended that 'Query Wizard' is used for this purpose).
'Query Designer' is available as follows:
A number of screens are available for selecting and sorting data. These screens are:
|
For selection of the Tables to be used in the report. |
|
|
To select the required Fields from the Tables selected on the 'Tables' screen. |
|
|
Calcs |
Not Used. Calculations should be entered on the Report Layout screen (see 'Editing the layout of a report'). |
|
Group |
Not Used. Groups should be entered either at the time of creation via Query Wizard or on the Report Layout screen (see 'Editing the layout of a report'). |
|
For entering criteria to reduce the data included in the report e.g. to include only a specific year or form group. |
|
|
To determine the order of the data within the report. |
|
|
Displays all data that has been entered into the query.
|
If creating a new Query using Query Designer, it is advised that the screens are completed in the order in which the individual tabs are displayed.
If amending an existing Query, select the required tab for amendment.
'Help' for entering/selecting data on each of the applicable screens is given below:
Tables
A list of all available Tables is offered for selection. These tables hold all those fields available for inclusion in the report e.g. the 'Forms' table holds a list of many of those fields held in an individual Form record.
|
Additional Help Topics:
|
Select the first Table required by double-clicking the mouse on the applicable 'Available Table' (in the 'Table' column).
The selected Table will be displayed on the lower half of the screen under 'Selected Tables'.
All currently 'linked' tables which have not yet been selected will then be displayed in bold text under 'Available Tables'. In the Example above, 'Forms' has been selected. Those linked Tables which are now available for selection are 'Current Pupils', 'Current Pupils All Years', 'Form Years', 'Past Pupils', 'Prospective Pupils' and 'Staff'.
If 'Current Pupil' is now selected, a list of all Tables linked to the 'Current Pupil' table will be available for selection, and so on.
|
Note: It is also possible to select tables which are not linked, so long as the User can provide a valid link - see 'Linking tables'. |
When all required Tables have been selected, go to the 'Fields'
tab to select the required fields to be included in the query, or select
one of the other available tabs to enter additional query detail, or select
(in the bottom right hand corner of the screen) to exit
from the query and save amendments.
Deleting Tables from the Query
To delete a Table from the Query,
In the 'Selected Tables' (lower) section of the screen, double-click the mouse on the Table to be deleted (in the 'Table' column).
When a Table is selected for deletion from the Query:
|
1. |
The selected Table will be deleted. |
|
2. |
All Tables which were selected after the Table to be deleted was selected (i.e. all linked tables) will be deleted. |
|
3. |
All Fields in all deleted Tables will be deleted. |
Fields
The 'Fields' screen is used to determine which of those Fields contained within the Tables on the previous screen are to be included in the Report Query. For example, if the 'Form' table was selected on the Tables screen, then a list of fields contained within an individual Form record will be available for selection.
|
Additional Help Topics:
|
All those Fields contained in the Tables selected on the 'Tables' screen will be offered for selection. Fields may be selected as follows:
Either,
Select 'All' fields within all selected Tables, by entering a tick in the 'All Fields' box.
Or,
Select each required fields by double-clicking the mouse individually on each required field (in the 'Field Alias' column).
All selected fields will be displayed on the lower section of the screen, under 'Selected Fields'.
When all required Fields have been selected, select one
of the other available tabs to enter additional query detail, or select
(in the bottom right hand corner of the screen) to exit
from the query and save amendments.
To remove a Field from the Query,
In the 'Selected Fields' (lower) section of the screen, double-click the mouse on the Field to be deleted. (in the 'Field Alias' column).
This Field will then be removed from the Query.
Calcs
It is advised that any required calculations are entered onto the Report Layout screen and not onto this 'Calcs' screen. See 'Editing the layout of a Report' for further information on entering Calculations.
Search
Search Criteria may be entered to reduce the number of records to be included in the report. For example only those Pupils in a particular year group may be required, or only those records in a specific Academic Year. Any number of criteria may be entered to make the report as specific as required.
Search criteria is entered against a selected field. The field is first selected by double-clicking the mouse on the required field. The Search criteria for the selected field is then entered in the lower section of the screen.
For further information on entering Search Criteria, see 'Report Builder Search'.
To remove a Search line, highlight the required Search for deletion and double-click the mouse (in the 'Field' column).
The Search criteria will be removed.
Group
It is advised that any required Groupings are entered from the Report Layout screen and not on this 'Group' screen. See 'Editing the layout of a Report' for further information on entering Groups.
Group Search
See 'Editing the layout of a Report' for further information on entering Group Searches.
Sort
This screen is used to determine the order of the data within the report. The default for the report is 'Natural Order'. This means that the data will be listed in its natural (non-specific) order.
|
1. |
Select, by double-clicking the mouse, the required 'Field' from the top section of the screen which is to be used as the primary sort in the report. E.g. if the report (using the Form and Current Pupils tables) is to appear in 'Form Code' order, select 'Code'. The selected Order field will then be shown under 'Sort Fields' in the bottom section of the screen.
|
|
|
|
|
|
When the report is run using this report query, the records will be listed in Form code order. |
|
|
By default the Form order will be in ascending order. If Forms are to be listed in descending order, enter a tick in the 'Desc (z>a)' field. |
|
2. |
If, for example, within Form order, the report is to be listed in Pupil Code order, select 'Code' as the second sort.
|
|
|
|
|
3. |
Continue selecting additional fields for order purposes as required. The second selected field will be a sub-sort of the first. The third will be a sub-sort of the second, and so on. |
|
|
Selected fields may be moved up and down the screen into
their correct position by highlighting and using |
|
4. |
When all Sort requirements have been entered, click on |
To remove a Sort line, double-click the mouse on the Field to be removed, in the 'Sort Fields' (lower) section of the screen. (The cursor must be on the Sort field in the 'Field Alias' column to delete the Sort line).
SQL
This screen shows all detail that has been entered in the Query. It is advised that no amendments are made directly to this screen.