Fork me on GitHub
#datomic
<
2020-06-29
>
joshkh16:06:06

are these two constraints equivalent when finding entities that are missing an attribute?

{:where [[(missing? $ ?n :item/sale?)]]}

{:where [(not [?n :item/sale?])]} 

favila16:06:22

Yeah, pretty much. missing? is a function call, not should be visible to the query planner. I don’t know if the query plan is different in any important way.

favila16:06:42

historical note, not came later

favila16:06:06

missing? probably doesn’t work on datasources which are not databases, but I don’t know that for sure

joshkh16:06:14

cool, and as always thanks