#+BEGIN_QUERY
{
:title [:h2 "informs ->"]
:query [
:find (pull ?p [*])
:in $ ?current-page ?relationship-page-name
:where
;; find all blocks that mention this page
(page-ref ?referring-blocks ?current-page)
;; filter for `[[relationship]] ->` child blocks
[?child :block/parent ?referring-blocks]
(block-content ?child "->")
(page-ref ?child ?relationship-page-name)
;; find pages referenced
[?b :block/parent ?child]
[?b :block/refs ?p]
]
:inputs [:current-page, "relationship/informs"]
}
#+END_QUERY