This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2021-10-14
Channels
- # announcements (1)
- # asami (3)
- # aws (1)
- # babashka (22)
- # beginners (39)
- # calva (21)
- # clj-kondo (10)
- # cljdoc (22)
- # cljs-dev (17)
- # clojure (93)
- # clojure-australia (3)
- # clojure-europe (39)
- # clojure-italy (3)
- # clojure-losangeles (17)
- # clojure-nl (14)
- # clojure-russia (2)
- # clojure-uk (5)
- # clojurescript (35)
- # community-development (7)
- # conjure (2)
- # cursive (13)
- # data-science (1)
- # datomic (25)
- # emacs (5)
- # events (4)
- # figwheel-main (2)
- # fulcro (12)
- # graphql (7)
- # gratitude (2)
- # inf-clojure (6)
- # leiningen (6)
- # lsp (49)
- # malli (13)
- # membrane (30)
- # minecraft (1)
- # pathom (3)
- # pedestal (26)
- # polylith (13)
- # portal (2)
- # quil (3)
- # random (1)
- # re-frame (13)
- # reagent (43)
- # reitit (6)
- # releases (1)
- # reveal (2)
- # ring (3)
- # shadow-cljs (30)
- # specter (5)
- # sql (8)
- # tools-build (1)
- # tools-deps (13)
- # videos (1)
Hi Sean and everyone
I’ve rather wide and controversial question/feature-request
A lot of folks using next.jdbc
and honeysql
together (but not all of course)
both next.jdbc and honeysql have a rules to convert sql field names into clojure keys and back
would be nice to keep those aligned or configured from one source
wdyt?
thanks
once source would imply 1 common dependency. AFAIK the projects are currently fully separated
I dont have a solution in my mind, just speaking out the probable improvement point
HoneySQL is about generating SQL. next.jdbc
is about running SQL and producing results. HoneySQL converts keywords/symbols to column names. next.jdbc
converts column names to keywords. The former just needs to produce valid SQL. The latter can be configured with any strategy you want (and there are camel-snake-kebab builders provided if you don't like the default strategy). They are otherwise unrelated.
By default, what next.jdbc
produces is acceptable to HoneySQL as input for insert
operations which is about the only point of interop.
I understand that, not a big deal for me, just seems like one global point of confiuration would make it cleaner
next.jdbc.sql
also converts keywords/symbpls to column names
Yes, but that is intended to be an extremely simple convenience -- it is not meant to be "full-featured". If you need more than next.jdbc.sql
provides, use HoneySQL. Per the docstring on that ns:
This is intended to provide a minimal level of parity with clojure.java.jdbc (insert!, insert-multi!, query, find-by-keys, get-by-id, update!, and delete!).
For anything more complex, use a library like HoneySQL to generate SQL + parameters.
(I should update that to use the new URL!).clear, thanks as i said before - not something really important 🙂