Skip to content
This repository has been archived by the owner on Jan 15, 2021. It is now read-only.

Use a value from key-value pair to be the doc id #36

Open
kyawzazaw opened this issue Feb 29, 2020 · 3 comments
Open

Use a value from key-value pair to be the doc id #36

kyawzazaw opened this issue Feb 29, 2020 · 3 comments

Comments

@kyawzazaw
Copy link

For example, I would like my doc id to be the value from the key-value pair courseid
json

@dalenguyen
Copy link
Owner

@kyawzazaw you can run a loop locally to reformat the json file to bring out the courseid before importing back to the firestore.

You try this package, it's more up-to-date: https://github.com/dalenguyen/firestore-backup-restore

@kyawzazaw
Copy link
Author

@dalenguyen Thanks for your response. I am not quite clear what you mean.

Are you suggesting me to reformat the json file? And then process it?
Does the other package have this functionality?

@dalenguyen
Copy link
Owner

@kyawzazaw, in order to have the structure based on your need. You have to follow the format of your file in order to import correctly.

https://github.com/dalenguyen/firestore-import-export/blob/master/import-to-firestore.json

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants