How to save aute generated document id to its document as a property for Firestore?
Hi @Kai1! You can leave the document ID blank for auto-generating the id. Once the record is inserted, the document id will be available under the _id property. Would that work for you?
I would also like to user the autogenerated id on the addition of a document. How I currently do things on the firestore ui is I tap autogenerated id, then I create a id field in the document with that id. Is it possible to do that on Retool?
Hi @rlindsey2! Thanks for reaching out -- Retool should be handling the the creation of the
_id property already. To create your own
id field, you could chain a query on success of the insert query that adds the id to your document:
Is that helpful for your use case?