How to search with operators and wildcards

Impira enables you to run advanced search queries via operators (and, or) and wildcards (*, ?).

Example: Invoices

Let's run some search queries in this Collection of purchase orders.

We've already extracted fields like:

  • Name
  • Address
  • Company
  • PO Number
  • Phone Number

Operators

To search for files where the value of the Name field is "Kimberly Neal":

Name:`Kimberly Neal`

It should look like this:

Note: Use backticks to enclose any fields or values with spaces. "Kimberly Neal" is separated by a space, so the query above shows it encased in backticks. Single word values (like "Name") don't need backticks, though it wouldn't hurt anything to add them just for fun.

To search for files where the value of the Name field is "Kimberly Neal" AND the value of the PO Number field is "39":

Name:`Kimberly Neal` `PO Number`:39

It should look like this:

To search for files where the value of the Name field is "Kimberly Neal" OR the value of the PO Number field is "39":

Name:`Kimberly Neal` or `PO Number`:39

It looks like this:

To search for files where the value of the Name field is "Kimberly Neal" and the value of the PO Number field is not "39", include a minus symbol:

Name:`Kimberly Neal` -`PO Number`:39

It looks like this:

Tip: Backticks — the apostrophe lookalike

Backticks look a lot like apostrophes (ʼ) or single quotation marks (‘), so make sure you pick the right symbol on your keyboard as you write queries.

Image credits: Apple and Keychron

Range

To set lower and upper bounds in a query, you can also use range operators, such as > (greater than) or < (less than).

The syntax is as follows:

The following query free-text searches for “motherboard” in files where the Quantity field is less than 10 and the Date is greater than (i.e., comes after) March 23rd, 2020:

motherboard Quantity:<10 date:="">2020-03-23</10>

Wildcards

You can also use wildcards in your searches to match fields where the term given in the query is part of a longer string.

Impira supports the following wildcards:

  • Asterisk (*): Matches any character sequence (including the empty one)
  • Question mark (?): Matches any single character

For example, the query below matches any filename that ends with .jpg:

The following query would return matching search results for files containing values that start with "A," have any two characters in a row, then end with "le."

This query could return results like: Apple, Addle, A48le, or Ankle:

© 2023 Impira Inc. All rights reserved. This site is built with Motif.