Reputation: 117
I have my Cloud Firestore database as follows
Here Education
is a map and Skills
is array. I have couple more arrays and maps. How can I edit these values with flutter.
I was guessing maybe like
return Firestore.instance.collection('data/users/$uid')
.document('user_data')
.updateData({
"Education[High school]" : _highSchool,
});
}
Upvotes: 1
Views: 1301
Reputation: 631
didn't test it but maybe this will work
return Firestore.instance.collection('data/users/$uid')
.document('user_data')
.setData({
"Education.High school" : _highSchool,
});
}
also there is similar question like that check it out Update the Map field - Flutter
Upvotes: 3