[SOLVED]How do you display the container name from the firebase real time database

let me show you the exact problem

when I run this it shows the end element in the database, which is cool since I want that too

Screenshot 2024-05-25 114348
Screenshot 2024-05-25 114434

but when I want text of one of the containers

Screenshot 2024-05-25 114614

doing this

does not work

Screenshot 2024-05-25 114805

and if i say generate JSON then it shows everthing inside the table
how do i solve this ??

helpp

You can get a property name by using this block:

image

So you would want to get the object properties of cloud variable “users/user1” which would return a list of all property names under that path. And then you can use List blocks to get a specific value from that list.

i tried using
get object properties block

but it simply doesn’t connect to other blocks

can you maybe show more explanation or how I can modify the whole code block to get the items

I’m on my phone so I can’t give you an example of the blocks but you can set an app variable to the get object properties block and then use that variable wherever you need to access those values.

In a nutshell the problem is that from firebase database I am able to get the end object but not container name inside which the object is placed

here I the link to the video, exactly explaining my question.

Hello @itsvedanttikareztlgx
Here is an example using the “Get Object Properties of” block:

1 Like

@itsvedanttikareztlgx you populate the object properties to a simple list for debugging to make sure you’re getting the expected output.


I tried to mock up your example data using this JSON:
{“users”: {“users1”:{“inventory”:{“item1”:{“item1name”:“iOS device”,“item1quantity”:5},“item2”:{“item1name”:“android device”,“item1quantity”:22}},“personal”: {}, “business”:{}}}}

yes this works thank you very much for your help

1 Like

thank you very much this works and it also solves another question I had.
happy tuesday✨

1 Like