Fetch user data from firebase based on given last name

I'm trying to make a simple contacts app, where you save the contact's name, last name and number, and then display the contact info when searching in a TextBox for the contact's last name, bringing also other contacts with that same last name, in a listview. Can i perform that with this Firebase structure?


I have done some work on this for you. I have used the firebase component in order to create the contacts, and the REST api with the web component to work with the firebase data directly (as opposed to calling down all the data then querying it on the app). This requires the setting of an index on the rules...


You type the beginning of the lastName into the textbox, then press the button, it will return any contacts that match.

Is this what you are looking for ?

1 Like

That's exactly what i was looking for, thank you a lot, really! Also, let me ask you, do you know if it's possible to extract those values gotten from the response and display them in a listview component? I'm relatively new on AI so i'm not sure if this can be accomplished. Thanks in advance.

Yes, it is possible.

You need to extract your desired items from the returned json using the dictionary blocks, and then apply them to a listview.


First time seeing how to use the index on technique for Firebase query method. Thanks @TIMAI2 , you are always rocking and making us to learn.. :pray:

(Earlier I tried but failed to add those bracket so unable to get result. )

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.