# Elastic Search .Net client doesnt have Fuzziness?

**URL:** <https://discuss.elastic.co/t/elastic-search-net-client-doesnt-have-fuzziness/343176>\
**Category:** Elasticsearch\
**Tags:** language-clients, eql-elastic-query-language, async-search\
**Created:** [September 16, 2023, 12:30pm UTC](https://discuss.elastic.co/t/elastic-search-net-client-doesnt-have-fuzziness/343176 "2023-09-16T12:30:24Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![senadk](https://avatars.discourse-cdn.com/v4/letter/s/b2d939/32.png) [@senadk](https://discuss.elastic.co/u/senadk)\
**Post date:** [September 16, 2023, 12:30pm UTC](https://discuss.elastic.co/t/elastic-search-net-client-doesnt-have-fuzziness/343176/1 "2023-09-16T12:30:24Z")

</div>

Hello,

Im having trouble with adding Fuzziness to my Match query, see the below code:

```auto
 var client = new ElasticsearchClient(new Uri("http://elasticsearch:9200"));

            var response = await client.SearchAsync<ExceptionLog>(s => s
               .Index("exceptions")
               .From(0)
               .Size(1000)
               .Query(q => q
                    .Bool(b => b
                       .Must(m => m
                       .Match(ma => ma
                            .Field("message")
                            .Query(message)
                            .Operator(Operator.Or)
                            .Fuzziness(Fuzziness.) //i want here AUTO fuzziness but it only has Equals and ReferenceEquals.
                            .ZeroTermsQuery(ZeroTermsQuery.All)
                       )
                    )
               )
                    )
               .Sort(sort => sort
                   .Field("createDate", new FieldSort { Order = SortOrder.Desc })
               )
               );

```

Below is the normal query that works fine, but how to get it in my .net code:

```auto
 {
        "match": {
            "message": {
                    "query": "",
                    "operator": "or",
                    "fuzziness": "AUTO",
                    "zero_terms_query": "all"
                }
            }
        },

```

Im using Elasticsearch net 8.9.3 : [GitHub - elastic/elasticsearch-net: This strongly-typed, client library enables working with Elasticsearch. It is the official client maintained and supported by Elastic.](https://github.com/elastic/elasticsearch-net)

I already tried without fuzziness (maybe its by default Auto) but that doesn't work.

Any help is really appreciated! Thanks!

---

<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:** [October 14, 2023, 12:30pm UTC](https://discuss.elastic.co/t/elastic-search-net-client-doesnt-have-fuzziness/343176/2 "2023-10-14T12:30:46Z")

</div>

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