There are examples of fuzzy matching on the official website.

I tried it out for myself:

Similar to Ma Dongmei, ma Dongmei?

But look at ES’s own official blog:

Blog.csdn.net/ubuntutouch…

While we got the results we wanted above, we have to keep the following things in mind when actually using regexp searches:

  • Avoid wildcard characters in front, such as.*work above. It is possible to index data in a way that avoids the use of leading wildcards
  • In general, regular expressions can be expensive

If oriented to the C end user. Be cautious. Affecting the overall ES performance, that’s a big deal.

If the function is to the back end of their own query, also to OK.

The official website gives an optimization scheme, index inversion, and then build a reverse index, reverse check, always feel strange.