0

I started to construct an app on Android using Firebase where users can post items to a live feed (recipes).

Everything was going great until I realized that as the number of posts grew, users would need a way to filter through all of the recipes.

For example, if they wanted to find all chicken dishes, they need to be able to search for chicken and see all recipes containing the word chicken.

The problem is that, as far as I can tell, you can only query for exact strings with Firebase. e.g. You can search for all recipes precisely titled "Chicken Parmesan" but you can't do a general search for all recipes containing the word "chicken".

Is there any way around this, or am I better off going for a relational DB setup?

Community
  • 1
  • 1
user2805004
  • 193
  • 1
  • 1
  • 6
  • have you try firebase Query class? – Hamza Sep 15 '16 at 06:16
  • This has been discussed quite a few times before. Firebase is not a full-text search index. Your most feasible option is to use a secondary search engine such as ElasticSearch or Algolia. See http://stackoverflow.com/questions/10559191/firebase-and-indexing-search/10559689#10559689, http://stackoverflow.com/questions/33867185/searching-in-firebase-without-server-side-code, http://stackoverflow.com/questions/34676208/firebase-queries-on-large-datasets/34687138#34687138 – Frank van Puffelen Sep 15 '16 at 14:26
  • Thanks for the responses. I'll look into those resources. – user2805004 Sep 15 '16 at 18:43

0 Answers0