Our colleague Gianluca kindly sent me these codes to save this data in the firebase database.
Since access is now done via email and password, my structure is as follows:
What I want is for each user to have their own registration and then create their own budget. In this structure that Gianluca created, the data is somewhat “loose.”
Structure model:
RaYzZz
(Gianluca Franco)
September 22, 2025, 12:42am
2
Hi Carlos,
This was the post where I explained how to use all these blocks:
https://community.kodular.io/t/data-is-not-being-written-to-firebase/300898/4?u=rayzzz
It seems that your data structure isn’t consistent.
Inside uid, you either have a value like "xyz34" or a dictionary.
It should look like this, correct?
"users": {
"xyz34": {
"image": "image",
"email": "email@email.com",
"name": "xpto"
}
}
If that’s the case, you would just need to add the new uid node to the GetValue and GotValue.
Glich
(Mahir Labib)
September 22, 2025, 9:07am
3
Solution
Right now, your Firebase structure is a bit loose because cadastro and orcamento are outside the user node.
If you want each user to keep their own registration and budgets, the best practice is to store everything inside the user’s UID .
Recommended Firebase structure
orcamento_compras:
users:
xyz34:
image: ""
email: "xpto@gmail.com"
name: "xpto"
cadastro:
- hipermercado: "Villerfort, BH"
produto: ["arroz", "feijão"]
marca: ["Vilma", "Camil"]
orcamento:
- data_orcamento: "11/09/2025"
hipermercado: "Villefort"
produto: "arroz"
marca: "Camil"
preco: "R$ 20,00"
Why this is better
All user data stays under their UID .
Easy to fetch only that user’s info, e.g.
orcamento_compras/users/xyz34/orcamento
Supports multiple users (abc12, def56) without mixing data.
In Kodular (Firebase blocks)
Save cadastro
Use FirebaseDB.StoreValue
Tag: orcamento_compras/users/<uid>/cadastro/<unique_key>
Value: registration info (hipermercado, produto, marca).
Save orcamento
Use FirebaseDB.StoreValue
Tag: orcamento_compras/users/<uid>/orcamento/<unique_key>
Value: budget info (date, hipermercado, produto, price).
Glich
(Mahir Labib)
September 25, 2025, 4:53am
5
Thanks for sharing your blocks.
Now, what kind of problem do you face?
Explain it clearly for better understand .