walkable-server / walkable

A Clojure(script) SQL library for building APIs: Datomic® (GraphQL-ish) pull syntax, data driven configuration, dynamic filtering with relations in mind
https://walkable.gitlab.io/
Eclipse Public License 2.0
444 stars 15 forks source link

Implement EXISTS #150

Open myguidingstar opened 5 years ago

myguidingstar commented 5 years ago

[:exists {:some-query-root-or-join [:table/column]}] should expand to EXISTS (SELECT a_column FROM some_table) the problem is the s-expression compiler need emitter from floor-plan to compile so it should be injected to the compiler's env somehow.

myguidingstar commented 5 years ago

the problem is EXISTS doesn't live in the same level as COUNT(*) > 0, so the sql query must be built specifically for it