Is there a way to query for entities that don't have a certain attribute? Something like "show me all entities that have a :company/id but don't have a :company/owner"
missing? in the query docs
Looks like that
datomic-peer do not respect socks proxy JVM props
Is it a know issue?
slurp respect this settings both for dns resolution and packages.
Datomic do not respect the proxy for names resolution
I can't know about packages
Hi, I want to restore my backup db then I run
bin/transctor the transactor
and I ran this command and I got an error
datomic-pro-0.9.5561 bin/transactor config/dev-transactor-template.properties Launching with Java options -server -Xms1g -Xmx1g -XX:+UseG1GC -XX:MaxGCPauseMillis=50 Starting datomic:<dev://localhost:4334/<DB-NAME>>, storing data in: data ... System started datomic:<dev://localhost:4334/<DB-NAME>>, storing data in: data
Can someone help me?
datomic-pro-0.9.5561 bin/datomic restore-db backup.tgz datomic:<dev://localhost:4334/hummingbirg-dev> java.lang.IllegalArgumentException: :storage/invalid-uri Unsupported protocol: at datomic.error$arg.invokeStatic(error.clj:57) at datomic.error$arg.invoke(error.clj:52) at datomic.error$arg.invokeStatic(error.clj:55) at datomic.error$arg.invoke(error.clj:52) at datomic.backup$fn__19707.invokeStatic(backup.clj:306) at datomic.backup$fn__19707.invoke(backup.clj:304) at clojure.lang.MultiFn.invoke(MultiFn.java:233)
your backup (source) needs to be an unzipped backup, not a tar
I got the same error when I unzipped
it should be a directory
a top level dir with
values dirs inside of it
backup ls owner roots values
you need to make a URI for it
it will be like:
I'm now debugging this 401 issue in my own case, where Datomic fails to download consistently on Github Actions for CI purposes but not locally on my machine.
Okay, I don't get it...
or-join works completely different from what I expect. When there's no result fulfilling any of the clauses in
or-join it will match everything. Is that on purpose? How can I avoid that?
I thought this:
Would be equivalent to this:
(d/q '[:find ?eid . :in $ ?comp-domain ?comp-name :where (or-join [?eid] [?eid :company/name ?comp-name] [?eid :company/domain ?comp-domain])] db comp-domain (:company/name data)))
But it is not.
(or (d/q '[:find ?eid . :in $ ?comp-domain ?comp-name :where [?eid :company/domain ?comp-domain]] db comp-domain)) (d/q '[:find ?eid . :in $ ?comp-domain ?comp-name :where [?eid :company/name ?comp-name]] db (:company/name data))))
In the first query, you are getting all
?eid s because the or-join you specify does not unify with
?comp-domain. So, practically, the
?comp-domain/`?comp-name` in your
:in clause are not the same as the ones you use in the or branches of your
So your first query now says “Give me al entity ids of entities that have either a name, or a domain”, the bindings in your
:in make no difference
If you change
(or-join [?eid] ...) to
(or-join [?eid ?comp-domain ?comp-name] ...), do you get what you want?
Yes, that gives me an empty result, which is correct in this case
And it works for a valid binding too. Thanks! I misinterpreted how that first vector works in
or-join, I thought that is to declare the common variable.
Q: what’s the best way to query for the most recently created entity (with other conditions) in Datalog?
It declares what variables from outside the
or-join to unify with ^^
I can include a :where [?e :some/attr _ ?t] and then sort all results by ?t but it feels like there must be some way to use max to do this
Here are some interesting time rules: https://github.com/Datomic/day-of-datomic/blob/master/tutorial/time-rules.clj maybe that helps ^^
perfect! thank you 🙂
Not sure if your use is exactly in there, but I often use it as a reference if I want to find something history related 🙂
it’s a good start. I’ll be able to make it work from this
haha, teach a man to fish, and all 🙂
exactly. you supplied the bait