Understanding Filters (QuickQueries)
Topics
- Filter (QuickQuery) Overview
- Setting the Default Filter
- Applying an Existing Filter to a List Page
- Creating a New Filter
- Modifying or Deleting an Existing Filter
- Filter Parameters
Filter (QuickQuery) Overview
A filter is a pre-defined search/filter that you can use to quickly access a list of items that meet certain conditions. (These filters were formerly known as a QuickQuery or QuickQueries.) For example, you can set up a filter that displays a list of records assigned to a certain department or even a certain individual. Your agency administrator may set up filters and make them available for your use, or you can create your own filters.
Filters are available for use in a number of pages. If available, you will see a My Filters option on the Menu drop-down list and a My Filters section on the page toolbar with its own drop-down options listing the available filters.
On the Task Dashboard, you can filter the tasks that show by making a selection from the Filter drop-down list. You can also set a default primary filter by clicking the filter options button () or clear the filter applied by clicking the clear filter button ().
Setting the Default Filter
When you set up multiple filters, you can assign one as the primary (default) query. When you designate a filter as primary, Civic Platform automatically applies that filter each time you open the list portlet or tab.
- From the Task Dashboard, click the filter options button () to open the My Filters page. (Alternately, you can reach the My Filters page by going to .)
- Click the name of the desired filter.
Click the Primary button.
The system confirms the filter has been set as the primary filter.
Click Cancel to return to the My Filters page.
The selected filter should now show as Yes under the Primary column on the My Filters page.
-
Go back to the Task Dashboard and click the Refresh button ().
The page displays the results for the specific filter chosen, and the Filter menu shows the primary filter as the first option on the list.
- If you want to see the list of associated tasks for a filter, click Cancel on the My Filters page to return to the Task Management list, or go to (you may still need to click Cancel on the My Filters page to return to the list).
Applying an Existing Filter to a List Page
- Navigate to the page you want to work in.
From the My Filters drop-down list in the portlet toolbar, choose the desired query.
To apply the filter to a particular module, select a module from the Module drop-down list.
To apply the filter to all available modules, from the Module drop-down list.
To filter the contents of other list pages besides the record list page, select the desired filter from the My Filters drop-down list.
To remove all filter filters from the list, choose --Select-- from the Filters drop-down list.
The list updates to display only those records that match the filter specifications.
Creating a New Filter
You can set up a filter that reflects your own needs.
- Navigate to the page you want to work in.
- Hover over the Menu button to display a menu, then choose My Filters from the menu.
Click New.
A blank filter form displays.
Complete these fields (a red asterisk means it is a required field):
Name Enter a name for the filter. The name you enter appears in the filter drop-down list, so make sure the name is concise and meaningful. Description Enter a description to help you identify the purpose of the filter. Primary This field is optional. Select Yes to designate the current filter as the primary. The default setting is No. Only one filter can be primary at any given time. If you assign another filter as the primary, Civic Platform automatically resets the Primary field for all other filters to No. Use the Search By section to build your query as described below.
- Use Box A only if you are creating an extremely complex query that requires parentheses to group operations properly. For most filters, you can leave this box blank.
Use Box B to choose the portlet field that you want to use to build your query.
Note:The current portlet sets the available filter fields:
The filter fields for Record List portlet include all the record fields that display in the record search form, Application-Specific Info, Address Template, Owner Template, Parcel Template, and Module Name.
The filter fields for the Reference Address (Parcel, or Owner) Portlet include the address (parcel, or owner) fields, and Address Template (Parcel Template, or Owner Template).
The filter fields for other portlets are the fields that display in the search form of each portlet.
If you select Application-Specific Info (ASI) as the filter field in the drop-down, Civic Platform displays all the ASI groups in a pop-up window. Select an ASI group code from the ASI Group Code field, and then find and click the desired ASI field in the ASI Field tree to specify the field you want to filter.
If you select Address Template, Parcel Template, or Owner Template as the filter field in the drop-down, Civic Platform displays all the active template attributes in a pop-up window. Click the desired attribute to specify the field you want to filter.
- Use Box C to choose the Relational Operator you want to use. For a list of available operators, see Relational Operators.
- Use Box D to specify the variable or specific value against which you want to compare the field in Box B. You can manually enter a value into this field, or you can click the Variable Picker button to the right of the field and select a variable from the Variable list. For a list of variables, see Filter Parameters.
If you select a user-name-related field, such as Requester, as the filter field, Civic Platform displays three fields where you can specify the first name, middle name, and last name of a person, instead of one Value field. For a list of user-name-related portlets and filter fields, see User-Name-Related List Portlets and Search By Fields.
However, if you pick a variable as the search criteria, Civic Platform turns the three fields into a read-only Full Name field and populates the field with the specified variable.
- Use Box E only if you are creating a complex query that requires parentheses to group operations properly. For most simple filters, you can leave this box blank.
- If you are querying additional fields (for example, you want to query by date and/or by location), choose a logical operator in the fourth field to determine how you want to combine the fields. Choose AND if you want the query to use both this field and the next field to find matches. Choose OR if you want the query to use either this field or the next field to find matches.
If you are querying another field (see step 5f), click the New Field button. Otherwise, go to the next step.
Civic Platform adds a new Search By row below the one you just created.
- Repeat steps 5 and 6 for each additional field you want to add. When you have finished adding fields, continue to step 7.
- Click the Preview SQL button to view the SQL query statement in the Resulting Query field, which can help you identify any potential syntax problems before you save.
Click the Submit button.
The filter is now available in the current portlet.
Modifying or Deleting an Existing Filter
You can modify or remove filters you created as needed. However, filters created by administrators are read-only and are not editable.
To modify or delete a filter
- Navigate to the page you want to work in.
- Hover the mouse on the Menu button to display a menu.
Choose My Filters from the menu.
A list of filters displays for the current portlet.
- Click the link for the query you want to modify/delete.
- If modifying the query, update as needed. Click Delete Field to remove fields from your query as needed.
- To delete the query, click Delete.
Filter Parameters
You can use parameters to build queries on the filter form.
Variable | Description |
---|---|
$$DEPARTMENT$$ | The department to which the current user belongs. |
$$GAUSER ID$$ | The logged in user's ID. |
$$GROUP$$ | The logged in user's user group. |
$$MODULE$$ | The name of the module for which the query is applicable. |
$$ORGANIZATION$$ | All organizations. A Citizen Access term. |
$$OWNORGANIZATION$$ | The logged in user's organizations. A Citizen Access term. |
$$OWNLICENSE$$ | The logged in user's licenses. A Citizen Access term. |
$$PUBLICUSER_EMAIL$$ | The logged in user's email. A Citizen Access term. |
$$SERV_PROV_CODE$$ | The login user's agency code |
$$TODAY+/-#$$ | Today's date (the workstation system date), or a
range of days. For example: Enter
as the value for the Inspection Date field to return all records
with inspection dates in the past week. Similarly, enter
to return records with inspection
dates occurring in the week to come. |
$$TODAY+n$$ | Date range beginning with today's date. |
$$USERID$$ | The ID of the user currently logged on. |
$$USERFULLNAME$$ | The logged in user's full name. |
Relational Operators
Relational operators define the relationship between the field you select and the value you want to compare that field against. For example, if you choose the City field and enter Portland as a value, you can then pick which relational operator you want to define what data to find. If you want records for Portland, you can use =. If you want all records except for Portland, you can use !=. The table below lists the default relational operators available for use.
= | Equal to |
!= | Not equal to |
< | Less than |
<= | Less than or equal to |
> | Greater than |
>= | Greater than or equal to |
LIKE | Contains part of the field value. |
IS NULL | Use to identify field values that are empty (no field value entered). |
IS NOT NULL | Use to identify field values that are not empty (field value entered). |
CONTAINS | Contains all of the field value. |
User-Name-Related List Portlets and Search By Fields
List Portlet | Search By Field |
---|---|
AMS Asset CA List | Inspector |
AMS PM Schedule Log List | Processed By Staff |
Inspection Conditions of Approval List | Action by User Applied by User |
Inspection List | Inspection Contact
Name Inspector Requester |
My Workflow Task List | Action By (Staff)Assigned to Staff |
Record Conditions of Approval List | Action by User Applied by User |
Record Inspection List | Inspection Contact Name Requester |
Set Conditions of Approval List | Action by User Applied by User |