Efficient search

Simple terms and phrases

The search allows you to use simple terms, i.e. single words, and phrases, i.e. phrases composed of several words enclosed in quotation marks, e.g. "Nicolaus Copernicus University". If you use quotation marks, only those documents that contain the entire phrase will be searched.

 

Search terms can be combined using logical operators. You can also use so-called masking characters that replace any letters and numbers and their strings, search for similar terms that are within a certain distance from each other, or specify the priority of search terms.

Logical operators

  • AND also written as &&

- indicates that the terms connected by the operator must occur simultaneously in the document being searched. For example, a query in the form Copernicus && Chopin will select only those documents in which both names occur simultaneously. Using the AND operator is the search engine's default behavior when more than one word is entered, so the same result will be obtained by typing Copernicus Chopin.

  • OR also written as ||

- requires minimum one of the terms occur in the document being searched, e.g., the query Copernicus || Copernicus will select documents in which the astronomer's name occurs in at least one of the given forms.

Operatory logiczine or

  • NOT also written as !

- excludes from the list of results documents in which the negated term appears. For example, the query "Nicolaus Copernicus" NOT university will search for documents that contain the phrase "Nicolaus Copernicus", but do not contain the word university at the same time. This operator cannot be used alone, e.g. a query in the form of NOT "Nicolaus Copernicus" will not return correct results.

Operatory logiczne not

  • + (required term operator)

- searches for documents containing the term immediately following the "+", but not necessarily the other terms, e.g. +university library will select documents that must contain the word library and may (or may not) contain the word: university.

Operatory logiczne plus

  • - (operator of the banned term)

- works similarly to the NOT operator. The query "Nicolaus Copernicus" - "Nicolaus Copernicus University" will search for documents containing the name "Nicolaus Copernicus" but not the name "Nicolaus Copernicus University".

 Operatory logiczne minus

Masking signs

  • ? - replaces one arbitrary character. For example, the query Kowalsk? matches both Kowalski and Kowalska.

Znaki maskujące ?

  • * - replaces the string of characters, e.g. the notation: bu*a will result in a search for such words as buda, buddha, buddist, butonier, etc. The masking character must not be placed at the beginning of the search term.

 Znaki maskujące *

Fuzzy search

Fuzzy search is used in the case of simple terms similar to each other, e.g. Copernicus, Copernikus, Kopernikus. Documents containing these terms can be searched by adding a tilde character to the term: copernicus~.

 

The degree of similarity searched for, can be determined by a coefficient that varies from 0 (no similarity) to 1 (identical terms). By default, the similarity coefficient is set to 0.5. To change it, add a tilde character to the search term along with an explicitly specified coefficient, such as copernicus~0.3.

 Wyszukiwanie rozmyte

= Copernicus/Copernikus/Kopernikus

 

Proximity search

It is also possible to specify at what distance one of the search terms is to be located from another. For example, if we remember that the terms Choral-buch and Westpreussen appeared in the document at a short distance from each other, we can use the following query: "Choral-buch Westpreussen"~6.

 Wyszukiwanie według sąsiedztwa

= Address book of the city of Toruń /or/ Book of debts of the city of Toruń from the period of the Thirteen Years' War.

 

Determining the validity of the term

You can specify the priority of a search term by adding the ^ character along with a number (greater than 1). E.g., the query stempowski^4 grydzewski will return documents in which both surnames appear, but at the beginning of the list will be those in which the surname with a higher priority appears more often. The default search priority is 1.

Określanie ważności terminu 

 

Combining queries

Expressions in compound queries can be grouped together using parentheses. Such a procedure makes it possible to give complex queries an intended, unambiguous meaning, just as it happens in arithmetic operations.

 

Partial expressions inside the parentheses are processed first, followed by larger wholes. A query of the shape: "De revolutionibus orbium coelestium" AND (Copernicus OR Copernicus) will result in a search for documents that contain the title of Copernicus' work and his name in at least one of two forms.

 Łączenie zapytań

= „De revolutionibus orbium coelestium” Mikołaj Kopernik /or/ „De revolutionibus orbium coelestium” Nicholas Copernicus

 

Special signs

For understandable reasons, the characters used to build compound queries (+ - && || ! ( ) { } [ ] ^ " ~ * ? : \}) are treated differently during the search than the others: they act as elements of the query syntax, and not as particles of the search term. In order to include them in the search process, it is necessary to put the so-called escape character \ in front of them. For example, to search for the phrase "(2 + 2)*2", you should type "\( 2 \+ 2 \) \* 2".

Znaki specjalne 

 

Description source

Full description of how to formulate queries (page in English): Jakarta Lucene Query Parser Syntax. Text originally posted on the Cuyahoga-Pomerania Digital Library website. Creative Commons License This work is available under the Creative Commons Attribution-ShareAlike 2.5 Poland License.

We use files, through the cookie quality improvement layer of our website.For more information, please read the document Privacy Policy