JSP Searches
Defining Default Query Filters
Query filters can be applied to each log available in the system. As a default, the logs are not restricted so they show all data available to the user. But as a project continues, it may be advantageous to limit the defaults to show only recent data, or open data, so that less data is displayed and it is easier and quicker to go directly to the required information. Even if a filter is put in place, it can be changed at any time.
Standard Treeview path: CMiC Field > File Maintenance > Default Filters
To apply a default filter to a log, open the System Log Filters screen in CMiC Field as shown in the screenshot above. This screen displays all of the system logs available in CMiC Field. Select the log requiring a default filter.
Standard Treeview path: CMiC Field > File Maintenance > Default Filters – Communications log
The Query Filters screen will display every field available for the selected log. Select which fields are to be visible to the query filter screen and what, if any, query conditions should be the defaults.
Standard Treeview path: CMiC Field > Communication Management
These filters are the default filters that are applied to the Data Filters section on a given log, launched from the log's [Show Filter] button. This will filter what data appears in the log, but is a separate filter from the filters that are directly available in the log component (i.e. Kendo).
Adding/Removing Fields
The only fields available are those that are shown on the Query Filters screen. By adding or removing fields, you are changing the look of the query filter. To add a field to the filter, check the 'Visible' checkbox. To remove a field, uncheck the checkbox.
Changing the Order
To change the order of the fields not automatically shown in the query filter, use the action icons of (Move Up) or (Move Down) to change the position of a specific field.
Defining the Condition
The Operator column allows you to select one of the following standard operators:
Operator |
Meaning |
---|---|
= |
Equals |
!= |
Not Equal |
> |
Greater Than |
=> |
Greater Than or Equal to |
< |
Less Than |
<= |
Less Than or Equal to |
IN |
Within a stated set of values |
NOT IN |
Not in a stated set of values |
LIKE |
Value like a stated value using wild characters |
NOT LIKE |
Not like a stated value using wild characters |
BETWEEN |
The value in between two stated values |
NOT BETWEEN |
The value is not between two stated values |
IS NULL |
The value is blank |
IS NOT NULL |
The value is not blank |
Once the Operator is selected, the matching condition needs to be entered in the Value Column. There is one system defined variable that could be very useful to you, this is 'SYSDATE' – this returns the current date, so if you use a posting date greater than or equal to SYSDATE –120 you will be asking for all records that have been posted in the last 120 days.
This type of filter keeps the log more or less current, but you can still change the filter to view all records.
Other types of common filters are:
-
Where Status != 'Closed'
-
Where Received = 'Yes'
-
Where Contact = 'Me'
Each filter can have multiple conditions applied, each is just another 'AND' statement.
Depending on your security privilege, the [Save As System Defaults] button will be active or not. If the button is active and used, the system will save the defaults entered for ALL users. If the [Save] button is used, it will only save the defaults for the current users.
The [Reset To System Defaults] button will reset the defaults to either nothing or to the 'Defaults' defined by the Administrator.
Be aware that it is possible to mark items as visible to the query filter but apply no filter – this means that you want the field to be available but are not restricting it for the default query. Also, if any query filters are applied to items that are not visible, they will always be used in the query even though they can’t be updated.
Substitution variables may also be used in filters. These include:
-
&today
-
&username
-
&userid
-
&partner
-
&partnertype
-
&contact
NOTE: Do not put single quotes around the filter value when using parameters like &today.