Skip to content

Commit

Permalink
[Docs] Clarify behaviour of Pattern Capture Token Filter during search (
Browse files Browse the repository at this point in the history
#26278)

There was some confusion about the fact that tokens emitted from a Pattern
Capture Token Filter are treated as synonyms when used to analyze a search
query. This commit adds an explanation to the note in the docs to emphasize this
behaviour.

Closes #25746
  • Loading branch information
cbuescher committed Aug 21, 2017
1 parent c49675e commit 8e9da55
Showing 1 changed file with 6 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -131,10 +131,12 @@ Multiple patterns are required to allow overlapping captures, but also
means that patterns are less dense and easier to understand.

*Note:* All tokens are emitted in the same position, and with the same
character offsets, so when combined with highlighting, the whole
original token will be highlighted, not just the matching subset. For
instance, querying the above email address for `"smith"` would
highlight:
character offsets. This means, for example, that a `match` query for
`[email protected]` that uses this analyzer will return documents
containing any of these tokens, even when using the `and` operator.
Also, when combined with highlighting, the whole original token will
be highlighted, not just the matching subset. For instance, querying
the above email address for `"smith"` would highlight:

[source,html]
--------------------------------------------------
Expand Down

0 comments on commit 8e9da55

Please sign in to comment.