This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2016-06-24
Channels
- # admin-announcements (2)
- # beginners (46)
- # boot (8)
- # cider (29)
- # cljs-dev (45)
- # cljsjs (10)
- # cljsrn (13)
- # clojure (60)
- # clojure-dev (5)
- # clojure-greece (1)
- # clojure-ireland (4)
- # clojure-mexico (6)
- # clojure-poland (3)
- # clojure-quebec (3)
- # clojure-russia (8)
- # clojure-spec (89)
- # clojure-uk (70)
- # clojurescript (84)
- # cursive (4)
- # datomic (7)
- # devcards (1)
- # dirac (2)
- # emacs (11)
- # hispano (10)
- # jobs (13)
- # keechma (34)
- # lein-figwheel (4)
- # luminus (19)
- # off-topic (2)
- # om (78)
- # onyx (6)
- # parinfer (1)
- # planck (82)
- # proton (2)
- # re-frame (10)
- # reagent (23)
- # ring-swagger (5)
- # spacemacs (2)
- # specter (24)
- # spirituality-ethics (122)
- # untangled (13)
@dilin I can help with HugSQL questions. Also, feel free to post a question as a github issue: https://github.com/layerware/hugsql/issues
@curtis.summers: in HugSql I read > :query and :execute mirror the distinction between query and execute! in the clojure.java.jdbc library and fetch and execute in the clojure.jdbc library.
but I really cannot find what is this distinction (sorry to ask, but I swear I googled a lot and even checked the src)
from clojure.java.jdbc/execute!
> Given a database connection and a vector containing SQL (or PreparedStatement) followed by optional parameters, perform a general (non-select) SQL operation.
from query
> Given a database connection and a vector containing SQL and optional parameters, perform a simple database query. The options specify how to construct the result set (and are also passed to prepare-statement as needed)
so the former does not perform selects am I right?
@richiardiandrea: I think the general distinction is that query
is expected to return a result set.
oh ok, that's all? good 😄
oh @curtis.summers I might have an issue, discovered just now, sorry for my newbie questions..
but if I want to query jsonb with the ?
operator
should I escape it somehow?
example: WHERE scan_left @> '{}' AND scan_left ? 'url'
I believe the Postgresql JDBC driver lets you put a double-question-mark ??
for escaping.
@curtis.summers: yes it does, just confirmed it on SO
great!
tnx a lot
you're welcome!