I have a data structure like:
I want to edit the value of "test" key in "first" object. I followed the document on https://firebase.google.com/docs/firestore/manage-data/add-data
But it did not work for me.
The nodejs code:
var setAda = dbFirestore.collection('users').doc('alovelace').update({
first : {
test: "12345"
}
});
The result in firestore:
The "test2" key was gone. However, I only want to update the value of "test" and keep the "test2".
Any solution for this problem?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…