Perceptive Enterprise Search Query uses a specific Query Syntax to create queries in one form or another. In a Menu Assisted Query the Query Syntax is constructed for you when you click on certain buttons. In a Command Based Query you use the syntax explicitly by typing each operator along with your search terms.
The Query Syntax uses a combination of standard operators used across the world and operators specific to Perceptive Enterprise Search. It is a useful set of tools for narrowing a search to a very specific range of words or phrases. The Query Syntax consists of:
These operators are used to find the existence of terms within a document in relation to other terms.
AND | The documents retrieved must contain both the words/phrases you have typed. The terms can appear anywhere in the document unless modified by additional operators. |
OR | The document must contain at least one of the entered words or phrases. Both terms may be present. |
NOT | The retrieved documents must contain the first term and must not contain the second, no matter where else it appears in the document. |
XOR | The documents must contain either the first search term or the second but not both terms. |
EXCEPT | The retrieved documents must contain the first search term but only if the second term is not in the same paragraph as the first. Both terms can appear in the document but they cannot appear within the same paragraph. |
BUTNOT | The BUTNOT operator is an even more precise form of EXCEPT. The document must contain the first term and must not contain the second term immediately following the first. For example, the query "WORLD BUTNOT WORLD BANK" will find documents that contain the word "WORLD" and which may or may not contain "BANK" but will not find "WORLD BANK" where it appears as a phrase. |
These operators specify the location of each of your search terms in relation to each other within a document.
PHRASE | To find words which occur next to each other as a phrase just type the words as you would normally. In Perceptive Enterprise Search syntax there is no need to enclose phrases in quotes. | |
FAR FOLLOW | ... | The retrieved documents must contain both terms and the second term must follow the appearance of the first. The second term can be anywhere in the document as long as it occurs after the first. |
CLOSE FOLLOW | .. | The retrieved documents must contain both search terms occurring in pairs. That is, the second term must immediately follow the first if a document is to be retrieved, without a repeated occurrence of the first term. If the first term occurs multiple times before the second term then it is the inner-most pair which is selected. |
IN | The retrieved documents must contain the first term in a paragraph beginning with the second. | |
LABEL | Retrieved documents must contain a paragraph beginning with the specified search term. | |
IN PARAS | \\ |
Both search terms must occur within the specified number of paragraphs of each other.
Placing a number between the lines indicates the number of paragraphs separating
each term.
|
NEAR BY | // |
Both search terms must appear within the same paragraph. The order of appearance
within the paragraph is not relevant. Placing a number between the lines indicates
the number of words separating phrases.
|
With queries which use more than one search term certain words and operators take precedence over others. Some operators will always be read by Perceptive Enterprise Search before others, regardless of where they occur in your query. The order of precedence is as follows:
Where a query expression, or part thereof, contains several operators of the same precedence, Perceptive Enterprise Search will process them from left to right.
Parentheses (or brackets) allow you to control and define the order of precedence in complex queries as their use overrides the Perceptive Enterprise Search default searching order. They are not necessary in searches of two terms. However, when using queries with three or more terms parentheses can be invaluable in ensuring Perceptive Enterprise Search does exactly what you want it to.
Examples:
car allowance // manager OR salesperson
Using Query's default sequence, this will be interpreted as follows:
((car allowance) // manager) OR salesperson
...which means that documents need only to contain the word "salesperson" to be included with the more detailed search of "car allowance in the same paragraph as manager".
To change the query to "find the phrase car allowance in the same paragraph as manager or salesperson", use the following search:
car allowance // (manager OR salesperson)
When searching for numerical values within an index these operators allow you to specify a range values within which to search.
TO |
Specifies an alphabetic, numeric or date range to be searched. For example:
A123 TO A456...will find "A123, A124, A125" ... and so on to "A456". Note: for the TO operator to be used for dates the Intelligent Date Handling options must be selected for the index. |
GE |
Search for a numeric range greater than or equal to the specified value. For example:
GE 1000...will find "1000, 1001, 1002, 1003 ... 59001" |
LE |
Search for a numeric range less than or equal to the specified value.
For example:
LE 1000...will find "1000, 999, 998, 997 ... -59001" |
For increased accuracy when searching for numeric values select the Intelligent Number Handling option when creating your index.
Dates may be used as a search term if Intelligent Date Handling has been selected.
With Intelligent Date Handling set dates within your index will be found regardless of the way in which they are expressed in the documents. For example "February 10 2001", "2/10/01" and "Saturday, February 10, 2001" are all read as the same thing by Perceptive Enterprise Search. Relative or implied dates such as "March this year" or "two weeks from next Thursday" are not supported.
Date searching operators are:
AFTER | Search for documents containing dates falling after a specific date. |
BEFORE | Search for documents containing dates falling before a specific date. |
TO | Search for a range between and including the specified dates. |
Certain symbols can be used in place of letters or characters in query words to help refine or expand a query. Perceptive Enterprise Search will replace the symbols with letters according to its built-in logic and run the query on any resultant words. Using these symbols can save you having to think up and type all the permutations of a word that you need to include in a query.
Note that using these word expansion systems can still only retrieve words that are listed in your index.
* |
This is a wildcard symbol and can be used to search for any number of significant
characters.
|
? | This is a single-character wildcard symbol and can be used to search for any single character. For example, searching for "h?t" would match "hat" or "hit" but not "heat". Both forms of wildcard may be used together in any combination desired, e.g."un*gra?ing". |
~ |
Tense conflation (tense expansion). Asks Perceptive Enterprise Search to find all tense forms of the word
specified.
|
+ |
Toggle synonym expansion and thesaurus on or off. This symbol reverses the
automatic synonym expansion setting in the search page. By default synonym expansion
is set to on. Using this symbol in a query will turn it off for the word to which
it is applied. For more information about Synonyms see
Synonym Rings. If neither synonym expansion or the thesaurus are turned on in Options the + symbol will turn them both on for a given search term. If both are turned off in Options the + symbol will turn them both on. If only one option is active in Options the + symbol will switch it off (and leave the other option as it is) for a given search term. |
Perceptive Enterprise Search treats punctuation in a query in one of three ways:
Significant
This means the punctuated search word or phrase will match only with words or phrases
containing matching punctuation characters.
Insignificant
Perceptive Enterprise Search ignores the occurrence of specified punctuation in the text, meaning that a
search will bring up matching words and phrases whether punctuated or not.
Separators
Some punctuation marks will not be recognized as such by Perceptive Enterprise Search and treated the same
way as spaces between words. For example, 'over-charge' will be indexed as two words
- 'over' and 'charge'. By default the period, or full stop, is a punctuation character
and thus not indexed. However, Perceptive Enterprise Search can be configured to index a period when it
is embedded within a word.
You can change the configuration of punctuation in an index using Character Options.
Reserved words are those used as Perceptive Enterprise Search operators. For example: AND, OR, NOT, LABEL and EXCEPT. If you need to include a reserved word in a query, precede the word with an insignificant character such as an underscore (_). This is a signal to Perceptive Enterprise Search to include the word as ordinary text in the search and not as an operator. For more information about significant and insignificant characters see the Character Options.
The // and \\ operators can be included in a search, if necessary, by enclosing them in quotes (i.e."//" and "\\").
Common words are words such as I, THE, IT, IS and other words that frequently appear in many documents but do not frequently have a significant meaning. They are excluded from searches in order to save indexing space.
You will need to amend the Common Word list within Utilities if you wish to perform searches using words Perceptive Enterprise Search automatically defines as common. See Utilities for more information.
Perceptive Enterprise Search includes the ability to filter results based on file name, file path, file date or format. The easiest way to do this is by clicking on the filter option and filling in the form. However, you can also include filters in your query syntax. The filter keywords are global to the entire query so it doesn't matter where you place them. They must be followed by a quoted parameter. For example, FNAMELIKE "*.TXT". If you wish to specify a list of values delimit each with a semi-colon. For example: FNAMELIKE "*.TXT;*.DOC".
FNAMELIKE | The file name must match the wild card specification in the quoted parameter which follows. |
FNAMEUNLIKE | The file name must not match the wild card specification in the quoted parameter which follows. |
PATHCONTAINS | The full path name must contain the string in the quoted parameter which follows. |
PATHOMITS | The full path name must not contain the string in the quoted parameter which follows. |
CATEGORYLIKE | The document category must match the wild card specification in the quoted parameter which follows. |
CATEGORYUNLIKE | The document category must not match the wild card specification in the quoted parameter which follows. |
FILEDATEBEFORE | The file date as stored on disk must precede the date specified in the quoted parameter which follows. The date format must be YYYYMMDD. For example: CAT FILEDATEBEFORE "20031225". |
FILEDATEAFTER | Similar to FILEDATEBEFORE but the file date as stored on disk must follow the one given. |
INDEXEDBEFORE | The document must have been indexed prior to the date specified in the quoted parameter which follows. The date format must be YYYYMMDD. For example: CAT INDEXEDBEFORE "20031225". |
INDEXEDAFTER | Similar to INDEXEDBEFORE but the document must have been indexed after the date given. |
FIRSTDATEAFTER | The first date appearing in the text of the document must follow the one given. |
FIRSTDATEBEFORE | The first date appearing in the text of the document must precede the one given. |