From bb2cf7e6be2a92a954f596b5e241c81415d1310e Mon Sep 17 00:00:00 2001 From: patrykk21 <39259934+patrykk21@users.noreply.github.com> Date: Fri, 30 Nov 2018 14:30:23 +0100 Subject: [PATCH] [Docs] Clarify search_after behavior Closes #34232 --- docs/reference/search/request/search-after.asciidoc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/docs/reference/search/request/search-after.asciidoc b/docs/reference/search/request/search-after.asciidoc index 4efa69b49b0..53d25c613b9 100644 --- a/docs/reference/search/request/search-after.asciidoc +++ b/docs/reference/search/request/search-after.asciidoc @@ -37,6 +37,10 @@ of the sort specification. Otherwise the sort order for documents that have the same sort values would be undefined and could lead to missing or duplicate results. The <> has a unique value per document but it is not recommended to use it as a tiebreaker directly. +Beware that `search_after` looks for the first document which fully or partially +matches tiebreaker's provided value. Therefore if a document has a tiebreaker value of +`"654323"` and you `search_after` for `"654"` it would still match that document +and return results found after it. <> are disabled on this field so sorting on it requires to load a lot of data in memory. Instead it is advised to duplicate (client side or with a <>) the content