guard against uncomparable values

Signed-off-by: Sean Corfield <sean@corfield.org>
This commit is contained in:
Sean Corfield 2024-09-28 16:23:44 -07:00
parent 3ca197b45c
commit 7c0e25f253
No known key found for this signature in database

View file

@ -1060,7 +1060,9 @@
(defn- format-values [k xs]
(let [first-xs (when (sequential? xs) (first (drop-while ident? xs)))
row-ctr (and (sequential? xs) (contains? #{:row 'rows} (first xs)))
row-ctr (and (sequential? xs)
(ident? (first xs))
(contains? #{:row 'rows} (first xs)))
xs (if row-ctr (rest xs) xs)]
(cond (and (ident? xs) (contains? #{:default 'default} xs))
[(str (sql-kw xs) " " (sql-kw k))]