Right now, we don't handle assertions in the map shorthand, like
[{:db/id IDENT :db/attr1 VALUE1 :db/attr2 VALUE2 ...}]
That is equivalent to
[[:db/add IDENT :db/attr1 VALUE1]]
[[:db/add IDENT :db/attr2 VALUE2]]
This ticket tracks parsing such assertions into Entity instances, and transacting such Entity instances.
Datomic allows to drop the :db/id IDENT in nested entities (marked with :db/isComponent?) like
[{:db/id IDENT :db/ref-attr {:db/attr1 VALUE1 ...} ...}]
A tempid in the same partition as IDENT will be generated for the inner entity. And it's possible that even the outer :db/id can be dropped, automatically selecting :db.part/user, although I haven't tested this.
In the Clojure implementation, I expanded from a map into a vector before transacting. I'd very much like to avoid doing that, both to save allocations, and to potentially save tempid lookups; but it's not critical that we're optimal initially.
Right now, we don't handle assertions in the map shorthand, like
[{:db/id IDENT :db/attr1 VALUE1 :db/attr2 VALUE2 ...}]That is equivalent to
This ticket tracks parsing such assertions into
Entityinstances, and transacting suchEntityinstances.Datomic allows to drop the
:db/id IDENTin nested entities (marked with:db/isComponent?) like[{:db/id IDENT :db/ref-attr {:db/attr1 VALUE1 ...} ...}]A tempid in the same partition as
IDENTwill be generated for the inner entity. And it's possible that even the outer:db/idcan be dropped, automatically selecting:db.part/user, although I haven't tested this.In the Clojure implementation, I expanded from a map into a vector before transacting. I'd very much like to avoid doing that, both to save allocations, and to potentially save tempid lookups; but it's not critical that we're optimal initially.