I am using drupal 8, search api and solr on our site. In views, I am using full text search with direct query option. Search is working for multiple words. What I want is when I search with double quote, I want the result with exact match of query string. But putting double quote doesn't seem to have any effect on it. If I changed parse mode to multiple words, double quotes work but it doesn't return any result for query without double quotes. Can I even achieve it in single view display? Any workaround suggestion so that it works for query without double quotes but also respect double quotes to do exact match depending upon query.
1 Answer
Take a look at this issue:
keys of fulltext searches must be encoded as phrases for terms parse mode
A quick read indicates that you might be able to just escape the spaces, e.g foo\ bar.
Also see the view settings image in comment #10 of that issue.