dalenguyen / firestore-import-export

An application that can help you to backup and restore from Cloud Firestore | Firebase
https://www.npmjs.com/package/firestore-export-import
401 stars 109 forks source link

How to import Firestore Collection's Documents with List of Map having Timestamp fields? #29

Closed Subroid closed 4 years ago

Subroid commented 4 years ago

I'm trying this command obviously as guessing : node import.js firestore-export.json date=FoodGrains[0].product_adding_timestamp ^What I'm trying above is I have a List of Product objects as Maps in one Firestore Document and all these objects have two Timestamp fields "product_adding_timestamp" and "product_updating_timestamp". Trying the above-guessed command giving me this error : image Here's the screenshot of FoodGrains collection : image Here's the screenshot of fields every List object contains : image ^I want to import product_adding_timestamp field values as Timestamp object, not as Map of _nanoseconds and _seonds keys. Sorry. Because of not being a native English speaker I could not make this question brief.

Subroid commented 4 years ago

bump

dalenguyen commented 4 years ago

Hi @subrud, please the NPM package of this one. It solves the issue of timestamp.

https://github.com/dalenguyen/firestore-backup-restore