Hi there
I’d like to do a query of blocks that contain some certain keywords, for example A
and B
.
In markdown mode, property block is defined as following:
category::
type::
related:: A
keywords:: B
tags::
Using following statements to query failed to return results (returned almost all blocks).
{
:title [:h1 "A and B"]
:query [
:find (pull ?block [*])
:where
[?block :block/properties ?p]
([(get ?p :related) ?t]
[(str ?t) ?st]
[(clojure.string/includes? ?st "A")])
(
[(get ?p :keywords) ?s]
[(str ?s) ?sq]
[(clojure.string/includes? ?sq "B")])
]
:collapsed? false
}
What I hope to achieve is that if it contains A and B, it can be retrieved.
Can someone assist me? Thanks.