About
Cloud Firestore is a document database.
Articles Related
Structure
Key
Each document has a unique key that contains information such as:
- the document ID
- and the document path.
Key property | Description |
---|---|
key.app | The Firestore app name. |
key.id | The document's ID, or null if key.name is set. |
key.kind | The document's collection ID. |
key.name | The document's name, or null if key.id is set. |
key.namespace | Firestore does not support custom namespaces. The default namespace is represented by an empty string. |
key.path | The path of the document: the sequence of the document and the collection pairs from the root collection. For example: “Country”,“USA”, “PostalCode”, 10011, “Route”, 1234. |
Options
When you structure your data in Cloud Firestore, you have a few different options:
- Documents
- Multiple collections
- Subcollections within documents
Analytics
You need to export your data to bigquery See doc
BigQuery creates a RECORD data type (also known as a STRUCT) for the key, with nested fields for each piece of information.