We have several documents which have no word limit. It can have any no. of words. We indexed these document text and stored in elastic index. Now we want to find only the documents which have exact match of search string.
For example we have two documents.
Elasticsearch is a search engine based on the Lucene library. It provides a distributed, multitenant-capable full-text search engine with an HTTP web interface and schema-free JSON documents. Elasticsearch is developed in Java.
Elasticsearch is a search engine.Shay Banon created the precursor to Elasticsearch, called Compass, in 2004. While thinking about the third version of Compass he realized that it would be necessary to rewrite big parts of Compass to "create a scalable search solution". So he created "a solution built from the ground up to be distributed" and used a common interface, JSON over HTTP, suitable for programming languages other than Java as well.
Suppose we searched for string "Java" then it should return both document that is working in my case but if I search for "Java as well" than it is also returning both the documents. In this case it should return the second document in phrase match.
In this case If I enables the term vector than it is working but enabling term vector increasing the index size so I want to know any alternate method to do this thing because we have a lot of documents which have a lot of text.
Let me know if it is still not clear to you.