Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- (def conn (java.sql.DriverManager/getConnection "jdbc:postgresql://localhost:5432/db", "", nil))
- (def ctx (org.jooq.impl.DSL/using conn org.jooq.SQLDialect/POSTGRES))
- (defn parse-sql [query] (.parseQuery (.parser ctx) query))
- (defn select [body] (.select ctx body))
- (defn inline [value] (org.jooq.impl.DSL/inline value))
- (def a (select (inline 1)))
- (def b (parse-sql "select 1"))
- (log/info a)
- (log/info b)
- (log/info (= a b))
Add Comment
Please, Sign In to add comment