# Constant score + Fuzzy query issue

**URL:** <https://discuss.elastic.co/t/constant-score-fuzzy-query-issue/273779>\
**Category:** Elasticsearch\
**Created:** [May 24, 2021, 3:52am UTC](https://discuss.elastic.co/t/constant-score-fuzzy-query-issue/273779 "2021-05-24T03:52:13Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![jihyun\_ahn](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jihyun_ahn/32/77498_2.png) [@jihyun\_ahn](https://discuss.elastic.co/u/jihyun_ahn)\
**Post date:** [May 24, 2021, 3:52am UTC](https://discuss.elastic.co/t/constant-score-fuzzy-query-issue/273779/1 "2021-05-24T03:52:13Z")

</div>

We are using a constant score to ignore the distance score while using the Fuzzy Query. The result is successful.

However, the difference between the CPU usage of Elasticsearch and the one used with the Constant score is more than 2 times. (If we use the Constant score, the CPU usage is higher.)

See the query below.

```auto
Fuzzy only
  "query": {
    "bool": {
      "should": [
        {
            "fuzzy": {
                "name_jamo": {
                "value": "something",
                "fuzziness": "2",
                "prefix_length": 1,
                "max_expansions": 50,
                "transpositions": false,
                "boost": 0.5
                }
            }
        }
      ],
      "disable_coord": false,
      "adjust_pure_negative": true,
      "minimum_should_match": "1",
      "boost": 1.0
    }
  }

Constant score + Fuzzy
"query": {
    "bool": {
      "should": [
        {
            "constant_score": {
                "filter": {
                    "fuzzy": {
                        "name_jamo": {
                        "value": "something",
                        "fuzziness": "2",
                        "prefix_length": 1,
                        "max_expansions": 50,
                        "transpositions": false,
                        "boost": 0.5
                        }
                    }
                },
                "boost": 0.01
            }
        }
      ],
      "disable_coord": false,
      "adjust_pure_negative": true,
      "minimum_should_match": "1",
      "boost": 1.0
    }
  }

```

From common sense, it seems that the performance should be good when using the Constant score, but it is the opposite. Why?

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [June 21, 2021, 3:52am UTC](https://discuss.elastic.co/t/constant-score-fuzzy-query-issue/273779/2 "2021-06-21T03:52:41Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
