Add note about using ipv6 addresses in `query_string`.

This commit is contained in:
Adrien Grand 2016-05-04 08:30:28 +02:00
parent 8bdd319a80
commit 80dbe31d59
1 changed files with 17 additions and 0 deletions

View File

@ -108,3 +108,20 @@ GET my_index/_search
}
}
--------------------------------------------------
Also beware that colons are special characters to the
<<query-dsl-query-string-query,`query_string`>> query, so ipv6 addresses will
need to be escaped. The easiest way to do so is to put quotes around the
searched value:
[source,js]
--------------------------------------------------
GET t/_search
{
"query": {
"query_string" : {
"query": "ip_addr:\"2001:db8::/48\""
}
}
}
--------------------------------------------------