Open
Description
I am trying to run the following query:
(select sessions
(join events (= :events.sessionid :sessionid))
(fields :clinic :events.sessionid)
(where {:sessions.istrainingmode false
:sessions.sessionid [in
(intersect
(queries
(subselect events
(fields :sessionid)
(where {:name [like "%Write%"]}))
(subselect events
(fields :sessionid)
(where {:name [like "%Impedance%"]})))
(order :sessionid)))]}))
It fails because the inner query executes first and then the outer query fails on receiving the map. In these type of queries the entire query should be build first.