Skip to content
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
handle IN by passing in NULL if list is empty
  • Loading branch information
ibarrick committed Apr 23, 2019
commit 5d95346b1dce6ca0461046cec7560f23bbd0332d
2 changes: 1 addition & 1 deletion project.clj
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
(defproject org.batch/yesql "0.6.5"
(defproject org.batch/yesql "0.6.6"
:description "A Clojure library for using SQL"
:url "https://github.com/krisajenkins/yesql"
:license {:name "Eclipse Public License"
Expand Down
2 changes: 1 addition & 1 deletion src/yesql/generate.clj
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
(defn- args-to-placeholders
[args]
(if (in-list-parameter? args)
(clojure.string/join "," (repeat (count args) "?"))
(if (empty? args) "NULL" (clojure.string/join "," (repeat (count args) "?")))
"?"))

(defn- analyse-statement-tokens
Expand Down