Trying to search for '$'

I'm attempting to search for a '$' in a string field. I've tried all of the types of queries listed in the documentation, as well as the analyzers too. I can get a regex match for things like this:

  "query": {
    "query_string": {
      "query": "/[a-z]/$",
      "default_field": "search_field"

But, it's only matching the a-z characters and not return results with a $. Is it possible to do this?

It would probably help a lot if you explained in a little more detail what you already tried and why/how it did not work. Which analyzers did you create in order to test this? Can you also show some sample documents that you want to match? Maybe we don't need any custom analyzers if you are explaining your use-case in a little more detail.


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