Not all results are shown for query

I’ve got an index with a url field mapped like the following:

        "post_url" : {
          "type" : "keyword"

I found several documents with the same url while querying the index. They are all the same document, with differing ids. However, when I run the following query, only 1 document is returned.

  "query": {
    "bool": {
      "must": {
        "match": {
          "post_url": "<url>"

Can someone explain why only 1 document is being returned?


The documents should show up if the match is exact. Can you share maybe a gist with a recreation of the issue?

Thanks for the reply. Upon further inspection, the urls were not exactly equal. They were literally one character apart. Thanks though!

1 Like