hugsql

apeel 2020-01-28T16:44:26.016600Z

I'm trying to use a Clojure Expression, but am getting a "SQL is empty" exception from https://github.com/layerware/hugsql/blob/master/hugsql-core/src/hugsql/parser.clj#L267. I've stared at my SQL but don't see a problem, but I must be missing something. Any suggestions?

-- :name get-all-things-sql! :query :many
-- :doc list all things or things with the specified ids
SELECT id                            AS "thing/id",
       state                         AS "thing/state",
       created_at                    AS "thing/created-at"
FROM things
--~ (if (empty? (:thing/id-seq params)) "" " WHERE id IN (:value*:thing/id-seq)")
;