I want to update CategoryBalance of a Item 2. Being very new to Firebase and React Native, I am finding difficulty in accessing the CategoryBalance key.
I am using firebase.push() to add the following and I am not storing any keys.
{
CategoryName: "Item 4",
CategoryBalance: 0
}
If I use the following code, it is adding a new values (red box in the image). But I need to update in the node (green box in the image)
db.ref().update({
"CategoryBalance": 10,
"CategoryName": "Food Card 2"
})
I am posting this question after checking many examples and questions over internet. I couldn't find any solution. Any help on the code snippet is highly appreciated. Thanks in advance

