4

I want to implement a SearchView for my App wich is connected to Firebase Database.

Database Structure

And now I want to Search for a Name, like in the Picture "Jay No" and add it to a ListView, but I do not want to Search for a specific name, I want to search for Example for: "Jay" and then I want to receive every name in the Database which contains "Jay"...

How can I implement it?

Frank van Puffelen
  • 565,676
  • 79
  • 828
  • 807
Zocker Bros
  • 173
  • 1
  • 1
  • 9
  • 1
    Firebase Database queries do not support "contains" queries. You can get names that *are* Jay or that *start with* Jay, but not names that *contain* Jay. If such queries are necessary for your app, you should consider using another service that supports them. See https://stackoverflow.com/questions/22506531/how-to-perform-sql-like-operation-on-firebase – Frank van Puffelen May 28 '17 at 14:14
  • This is a fairly common problem. I don't think this should have been marked as a duplicate, even though one could construct their solution by the older question's answers. – Laczkó Örs Jul 03 '20 at 13:39

0 Answers0