• Home
  • Categories
  • Recent
  • Popular
  • Pricing
  • Contact us
  • Docs
  • Login
FusionAuth
  • Home
  • Categories
  • Recent
  • Popular
  • Pricing
  • Contact us
  • Docs
  • Login

multi_match query?

Scheduled Pinned Locked Moved
Q&A
elasticsearch query user-api
2
4
4.9k
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D
    dan
    last edited by 15 Jun 2020, 17:20

    Is it possible to use the multi_match ElasticSearch query with the /api/user/search endpoint?

    --
    FusionAuth - Auth for devs, built by devs.
    https://fusionauth.io

    1 Reply Last reply Reply Quote 0
    • D
      dan
      last edited by 15 Jun 2020, 17:21

      I believe so. When you use the query option, we are essentially passing that query object straight through.

      --
      FusionAuth - Auth for devs, built by devs.
      https://fusionauth.io

      1 Reply Last reply Reply Quote 0
      • U
        uhon
        last edited by 26 Aug 2020, 01:18

        I tried to use multi_match in search-query without success. The following query does not find users? Any suggestions why?

        {
          "bool" : {
            "must" : [ {
              "multi_match" : {
                "query" : "*",
                "fields" : [ "firstName^3", "lastName^3", "email" ]
              }
            } ]
          }
        }
        
        1 Reply Last reply Reply Quote 0
        • D
          dan
          last edited by 26 Aug 2020, 04:24

          It looks like multi match (at least as of 2019) doesn't support wildcards:

          [a] multimatch query requires match queries as its internal queries. And a match query doesn't support wildcards.

          https://discuss.elastic.co/t/query-with-multimatch-and-wildcard/189962

          Can you try with a non wildcard query?

          --
          FusionAuth - Auth for devs, built by devs.
          https://fusionauth.io

          1 Reply Last reply Reply Quote 0
          • First post
            Last post