January 2018
Intermediate to advanced
336 pages
7h 56m
English
Datomic needs to know about the attributes to be used for the entities in the database beforehand. Both attributes (schema) and facts (data) are transacted as datoms using the transact function of the datomic.api namespace. Datoms can be transacted individually or clubbed together as a part of single transaction by wrapping them in a vector (https://clojure.org/reference/data_structures#Vectors). For example, all the attributes for hhorder can be transacted using a single transaction by specifying all the entity maps together within a vector and passing that vector as an argument to the transact function as shown in the following example:
pedestal-play.server> (def result (d/transact conn [{:db/ident :order/name :db/valueType ...Read now
Unlock full access