This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2021-06-21
Channels
- # announcements (5)
- # babashka (81)
- # beginners (26)
- # calva (6)
- # cider (7)
- # clojure (26)
- # clojure-czech (1)
- # clojure-europe (19)
- # clojure-nl (4)
- # clojure-spec (5)
- # clojure-uk (21)
- # clojuredesign-podcast (2)
- # clojurescript (19)
- # conjure (6)
- # cursive (13)
- # datomic (2)
- # depstar (1)
- # editors (2)
- # graalvm (25)
- # honeysql (5)
- # jackdaw (4)
- # jobs (5)
- # lsp (8)
- # malli (13)
- # music (1)
- # polylith (3)
- # practicalli (1)
- # releases (1)
- # remote-jobs (2)
- # sci (10)
- # shadow-cljs (5)
- # sql (14)
- # tools-deps (25)
- # xtdb (65)
Looks like my builder macro worked. So now for some more black magic - can I make any assumptions regarding the order in which the columns return? getObject(String)
is slower than getObject(int)
@ben.sless Well, the columns are in a particular order — the “natural” query order — but your builder can’t know that without going into the ResultSetMetaData
and getting the column names (which seems to be part of what you are trying to avoid).
Maybe I can do it once then cache the result, unless that can theoretically change every time I run the query? My queries are pretty static, if it makes any difference
The order should match the query.
select
’ing explicit column names is going to be better/faster than *
(which requires some level of introspection).
(on both sides of the SQL/JDBC boundary!)