Usecases where relational database are not suitable
Essence of searching lies in its order. Everyone wants search results to be shown in such a way that best suited results are shown on top.
Relational database do not have such capability.
Elasticsearch on the other hand shows results on the basis of relevancy by default.
Setup
Same as used in previous example.
Problem Statement
Suppose user wants to search for shirts but he is interested in red colored shirts. In that case, results containing red and shirts keyword should come on top. Then results for other shirts should be shown after them.
Solution Using Relational Database Query
Output
Elasticsearch Solution
Conclusion
As we can see above Relational Database has returned results in some random order, while Elasticsearch returns results in decreasing order of _score which is calculated on the basis of relevancy.
We tend to make mistakes while entering search string. There are cases when user enters an incorrect search parameter. Relational Databases won't handle such cases. Elasticsearch to the rescue.
Setup
Same as used in previous example.
Problem Statement
Suppose user wants to search for shirts but he enters an incorrect word shrt by mistake. User still expects to see the results of shirt.
Solution Using Relational Database Query
Output
No results found
Elasticsearch Solution
Output
Conclusion
As we can see above relational database has returned no results for an incorrect word searched, while Elasticsearch using its special fuzzy query returns results.
Related Searches to usecases where relational database are not suitable
non relational database examplerelational vs non relational database performanceadvantages of non relational databasesrelational vs non relational database pptnon relational databases listnon relational database designnon relational database wikinon relational database tutorial