Bird
Raised Fist0

Which mapping type must be included in an Elasticsearch index to use percolate queries?

easy📝 Syntax Q12 of Q15
Elasticsearch - Advanced Patterns

Which mapping type must be included in an Elasticsearch index to use percolate queries?

{
  "mappings": {
    "properties": {
      "query": {
        "type": "???"
      }
    }
  }
}
A"percolator"
B"text"
C"keyword"
D"nested"
Step-by-Step Solution
Solution:
  1. Step 1: Identify required field type for percolate queries

    Elasticsearch requires a special field type called "percolator" to store queries for percolate queries.
  2. Step 2: Match options with required type

    Only "percolator" uses "percolator" type; others are for different purposes.
  3. Final Answer:

    "percolator" -> Option A
  4. Quick Check:

    Percolate field type = "percolator" [OK]
Quick Trick: Use "percolator" type for storing queries in mapping [OK]
Common Mistakes:
MISTAKES
  • Using "text" or "keyword" instead of "percolator"
  • Confusing nested type with percolator
  • Omitting the percolator field in mapping

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Elasticsearch Quizzes