Skip to Main Content               

FHS-PK | Searching Techniques: Near Operator & Within Operator

This Libguide provides the methods used to locate relevent information from databases

Near Operator and Within Operator

Proximity Search:

Proximity search enables you to locate keywords within a specified distance from each other. This is particularly useful when dealing with variations in terminology. It is ideal for searches involving multiple phrases for a concept with different combinations of the same words.

Refer to the database's Help tab to determine the correct symbol or command for proximity searching, as different databases use different syntax. There are two proximity operators: the "Near" operator and the "Within" operator.

Near Operator:

The NEAR operator is used to find search terms that are close to each other within a specified distance. It allows you to locate documents where the words are near each other but not necessarily in a specific order.

For example: health NEAR/5 policy

This finds results where "health" and "policy" appear within five words of each other, in any order.

Within Operator:

The WITHIN operator specifies that the search terms must be within a certain distance of each other, but typically in a specific order. It’s often used similarly to NEAR but with stricter proximity control.

For Example: heart WITHIN/2 diseases
This finds results where "heart" appears within two words before "diseases"

In the examples with the NEAR and WITHIN operators, the number (like "3" or "5") specifies the maximum number of words allowed between the two search terms.

Databases use the NEAR and WITHIN operators to control proximity searches. However, their specific syntax and usage can vary depending on the databse.

Scopus: Scopus uses W/n (WITHIN) for ordered proximity (e.g., treatment W/4 cancer) and N/n (NEAR) for proximity in any order, where "n" represents a number (e.g., 1, 2, 3, etc.).

Web of Science: Web of Science uses NEAR/n for proximity searches in any order (e.g., climate NEAR/5 change) and WITHIN/n for ordered proximity, where "n" represents a number (e.g., 1, 2, 3, etc.).

PubMed: Users can now search for multiple terms appearing in any order within a specified distance of one another in the [Title] or [Title/Abstract] fields.

To create a proximity search in PubMed, enter terms using the following format:

"search terms"[field:~N]

  • Search terms = Two or more words enclosed in double quotes.
  • Field = The search field tag for the [Title] or [Title/Abstract] fields.
  • tilde ( ~ ) sign
  • N = The maximum number of words that may appear between your search terms.

For example, to search PubMed for citations where the terms "hip" and "pain" appear with no more than two words between them in the Title/Abstract search field, try the search:

"hip pain"[tiab~2]

Read more.

OVID databases (such as Medline, Embase, and PsychInfo) use the 'adjn' operator, while EBSCO databases (CINAHL) use the 'Nn' operator.earching (n = the maximum number of words that can be between the words).

Senior Librarian

Profile Photo
Dr. Midrar Ullah
Contact:
+92 21 3486 4485