This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2017-12-19
Channels
- # adventofcode (82)
- # beginners (70)
- # boot (34)
- # boot-dev (13)
- # cider (45)
- # clara (4)
- # cljs-dev (3)
- # cljsrn (2)
- # clojure (91)
- # clojure-art (8)
- # clojure-czech (1)
- # clojure-dusseldorf (3)
- # clojure-france (11)
- # clojure-germany (1)
- # clojure-greece (39)
- # clojure-hamburg (1)
- # clojure-italy (24)
- # clojure-norway (2)
- # clojure-spec (7)
- # clojure-uk (31)
- # clojurescript (56)
- # core-async (7)
- # cursive (8)
- # data-science (10)
- # datomic (41)
- # duct (7)
- # emacs (1)
- # events (1)
- # fulcro (83)
- # graphql (6)
- # klipse (1)
- # leiningen (28)
- # lumo (67)
- # off-topic (14)
- # om (9)
- # onyx (3)
- # perun (4)
- # re-frame (22)
- # reagent (11)
- # ring-swagger (2)
- # rum (1)
- # specter (46)
- # sql (13)
- # uncomplicate (17)
- # unrepl (114)
anyone have knowledge storing byte arrays into PSQL?
I have a bytea
column I'm trying to store a nippy/freeze
'd (serialized compressed byte-array) value in.
If I (spit "out" (String. (nippy/freeze object)))
its 11 bytes, if I INSERT (nippy/freeze object)
its around 1200 bytes
which is the JDBC preferred way to do it: https://jdbc.postgresql.org/documentation/head/binary-data.html#binary-data-example
@owen I'm using HugSQL and I just store a byte-array directly to it
@danielcompton oh I was able to store it successfully, just confused if the inflation in byte size is preventable
from the PSQL docs: > bytea 1 or 4 bytes plus the actual binary string variable-length binary string
but I also stored a 99KB image in a bytea
field using the PSQL recommended practices in here: https://jdbc.postgresql.org/documentation/head/binary-data.html#binary-data-example and stilll saw an 11-12KB increase
How are you measuring the size?