Have a look here:
You can replace starts-with with includes or ends-with.
#+BEGIN_QUERY
{:query [:find (pull ?b [*])
:in $ ?s
:where
[?b :block/original-name ?n]
[(clojure.string/starts-with? ?n ?s)]]
:inputs [ "task.myName." ]
}
#+END_QUERY