This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2023-06-02
Channels
- # ai (1)
- # aleph (16)
- # announcements (1)
- # architecture (51)
- # babashka (32)
- # beginners (27)
- # calva (3)
- # clerk (1)
- # clojure (49)
- # clojure-art (1)
- # clojure-denver (6)
- # clojure-europe (70)
- # clojure-nl (1)
- # clojure-norway (56)
- # clojure-uk (2)
- # clojuredesign-podcast (4)
- # clojurescript (57)
- # clr (15)
- # community-development (3)
- # conjure (1)
- # core-async (10)
- # data-science (1)
- # datalog (2)
- # datomic (3)
- # emacs (12)
- # events (1)
- # gratitude (4)
- # honeysql (9)
- # hyperfiddle (86)
- # jobs (4)
- # off-topic (10)
- # pedestal (5)
- # portal (11)
- # practicalli (2)
- # reitit (7)
- # releases (3)
- # remote-jobs (1)
- # sql (15)
- # tools-build (8)
- # xtdb (4)
How to express in datalog that the entity is referenced by some other entity (but I don't need to capture info about referencing entity)?
A reference is a fact like any other. You can check if the fact is present.
[?person :person/children _]
Matches if ?person
has a fact with attribute :person/children
. Meaning ?person
has a reference to a child.
(You can elide trailing _
, so you can write [?person :person/children]
)
Other way round:
[_ :person/children ?child]
Matches if ?child is referenced by some entity through the :person/children
attribute.👍 1