Fork me on GitHub
#datomic
<
2016-05-03
>
Ben Kamphaus01:05:11

It serialized transactions to dev or another storage, not to mem, And yeah anon fns not passable to tx functions over wire.

rauh10:05:09

In all of: http://docs.datomic.com/excision.html The partitions are specified without a keyword (missing colon). Is this a mistake? On other pages it's all like :db/id[:db.part/db]

pheuter16:05:02

Anyone have any experience enforcing composite unique attributes? The documentation briefly alludes to transaction functions, but I’m not sure where to go from there.

Ben Kamphaus16:05:34

@pheuter: there are really basic examples in Clojure https://github.com/Datomic/day-of-datomic/blob/master/tutorial/transaction_function_exceptions.clj#L15 and Java https://github.com/Datomic/datomic-java-examples/blob/master/src/java/datomic/samples/TxFunctions.java#L37 but in practice I think many people lean more on defining an additional attribute for the composite key (i.e. a concatenated string).

pheuter16:05:42

@bkamphaus: thanks! will take a look. also interesting point about a composite attribute that serves as a concatenation.

dww17:05:04

Careful when you're choosing the attributes to concat--unless they've changed the contract, you can't rely on :db/ids to stay the same across db restores

Ben Kamphaus17:05:26

right, don’t use entity id as an external identifier in general. :db/id isn’t an attribute. simple_smile

mlimotte17:05:21

good tip. i hadn't thought about that before.

pheuter18:05:36

good point