Static and Variable Searches

Static Searches

A Static Search is one where you set the search values for users, essentially “hard-coding” the search values into the Search. Use Static Searches for values users search for often; all they need to do to run Static Searches is click Run Search and it will run automatically. To create a Static Search, when entering a Search prompt, replace the default prompt with a static search value enclosed in braces ( { } ).


Examples: Static Searches

Search Greater Than a Dollar Amount. Create a static Search for all purchase orders of more than $20,000 to search for POs where the Amount Field has a value greater than or equal to the static value of $20,000. Note the braces surrounding the search value.

 

Search for a Commonly Used Character. Create a Search where the vendor name equals {Brew Shop}. Then, whenever that Search is selected the results would be all documents where “Brew Shop” was found in the vendor name, without having to type “Brew Shop” every time to into the search field.

Search using the Current Date. Create a Search by building a Search for “Due Date Equals @today,” to find documents with a due date equal to the current date, and when you run the Search tomorrow, it will find the documents that are due on that date.

Search by Document Modifier. Create a Search for “Last Modified By Equals @fulluser” to find documents last modified by the user currently logged in. When the same Search is run by a different user, GlobalSearch will return the documents last modified by that person.

Search by Document Author. Create a Field called “Author” that allows you to indicate who in your organization has authored a document, and create with it an associated Field List populated with usernames from your Active Directory. Then build a Search for “Author Equals @user” to find documents authored by the current users. When the same Search is run by a different user, GlobalSearch will return the documents authored by that person.

Use Date Math to Find Documents in a Date Range. Create a Search to find the PO date, which is between today’s date and seven days into the future, using date math to configure like this:

Field                Condition                              Prompt/Value
PODate           Less Than or Equal To          {@today+7}
PODate           Greater Than or Equal To     {@today}


Variable Searches

Use a Variable Search when the results should be based on user input. Some or all search values are provided by the user in response to a prompt presented by the Search, allowing for infinite flexibility. When you create a Search, GlobalSearch defaults to a Variable Search.


Example: The Browse Search

The Browse Search that is usually created when an Archive is created is a great example of a Variable Search. The user sees prompts for each Index Field that existed in the Archive when the Archive and Browse were created and can then enter a Search value for one or more Index Fields.

A Browse Search may be created automatically when you create an Archive, if the Create a Browse Search checkbox is selected. Just remember that the Fields included in the Browse Search are those which exist at the time the Archive is created. If you add Fields to the Archive, criteria for those Fields are not automatically added to the Browse Search; you must edit the Search to add the new Fields. This applies to all Searches that may exist on an Archive. To save time with editing Searches, it's always a good idea to make sure you understand the field requirements and add them at creation time.

By default, the Browse Search uses the Equals Condition on all criteria for number and date fields, and the Contains condition on all criteria for character fields. Also by default, the Browse Search uses AND to concatenate all the criteria. You can change conditions and Advanced Grouping, add or delete criteria from the Browse Search. Although you can modify a Browse Search, best practice is to leave it as is. If you want a different Search, create a new Search instead.


Searches Using Both Static and Variable Criteria

A mixed Search can use both variable and static criteria. With Variable Searches users get to search for what they want to, and you need to create fewer Searches. However, using static criteria is critical to controlling which documents users can and cannot see. Using both types of criteria in a mixed Search keeps it both flexible and controlled for security.


Search for Both a Variable and a User

Create a Search calledVendor Name” which contains the prompts “Vendor Name Contains” AND “Indexed By Equals {@fulluser}.” This allows the user to put in all or part of a vendor name, and GlobalSearch will return records that match that condition, but only the ones that were indexed by the current user.