The JDBC side: the transformer decoding driver and string values into the registry's types; what PostgreSQL's JDBC driver returns and takes for a column, under the options that say what an application's next.jdbc does differently; and the row shapes its result set builders return. as-read and pgmalli.honeysql both read columns and key rows here.
The JDBC side: the transformer decoding driver and string values into the registry's types; what PostgreSQL's JDBC driver returns and takes for a column, under the options that say what an application's next.jdbc does differently; and the row shapes its result set builders return. as-read and pgmalli.honeysql both read columns and key rows here.
(array-type t {:keys [write]})An array argument of elements t: what :write's :array names an application sends ([:pg/array :sequential :set]: a typed Java array, a vector, list or set of t); :any without it, malli's default registry having nothing for what the driver takes (:pg/array is pgmalli's registry's).
An array argument of elements t: what :write's :array names an application sends ([:pg/array :sequential :set]: a typed Java array, a vector, list or set of t); :any without it, malli's default registry having nothing for what the driver takes (:pg/array is pgmalli's registry's).
(as-read registry name opts)The [:map ...] of a row as a JDBC result builder returns it; the options are documented on pgmalli.core/as-read.
The [:map ...] of a row as a JDBC result builder returns it; the options are documented on pgmalli.core/as-read.
(checked! schema opts)(checked! schema opts kind label)opts (nil is none) when schema takes them; an error naming what it does not, a misspelt key with the one meant, otherwise. kind and label say whose they are (options by default). A config's :db, which may hold a password, is left out of the error.
opts (nil is none) when schema takes them; an error naming what it does not, a misspelt key with the one meant, otherwise. kind and label say whose they are (options by default). A config's :db, which may hold a password, is left out of the error.
(column-read-type schemas s {:keys [read] :as opts})read-type of a column schema (without NULL) of a registry's schemas, a domain read as the driver reads its base; :read may still name the domain's type.
read-type of a column schema (without NULL) of a registry's schemas, a domain read as the driver reads its base; :read may still name the domain's type.
(column-write-type schemas s {:keys [write] :as opts})write-type of a column schema (without NULL) of a registry's schemas, a domain taken as the driver takes its base; :write may still name the domain's type.
write-type of a column schema (without NULL) of a registry's schemas, a domain taken as the driver takes its base; :write may still name the domain's type.
(enum-arg t {:keys [write]})An argument's type t when it is a list of labels ([:enum ...], an enum type's or a CHECK's) under :write's :enum, what a SettableParameter extension sends: the labels as strings, keywords or both ({:enum [:string :keyword]}); t otherwise.
An argument's type t when it is a list of labels ([:enum ...], an enum type's or a CHECK's)
under :write's :enum, what a SettableParameter extension sends: the labels as strings,
keywords or both ({:enum [:string :keyword]}); t otherwise.The options pgmalli.honeysql takes: as-read's, and those of query data.
The options pgmalli.honeysql takes: as-read's, and those of query data.
(read-options builder)The reading options of a next.jdbc result set builder named by its symbol; documented on pgmalli.core/read-options.
The reading options of a next.jdbc result set builder named by its symbol; documented on pgmalli.core/read-options.
The options as-read takes, closed: a misspelt key or value is an error rather than a check silently weakened.
The options as-read takes, closed: a misspelt key or value is an error rather than a check silently weakened.
(read-type schema {:keys [read] :as opts})A column's schema (without NULL) as PostgreSQL's JDBC driver returns it through next.jdbc: dates and timestamps under :time (inst? by default), an array a java.sql.Array, json and jsonb a PGobject, an interval a PGInterval, citext, bit(n > 1) and bit varying a PGobject (these :any); real a Float, bit(1) a Boolean, numeric a Double for NaN, time and timetz a java.sql.Time under every :time (next.jdbc.date-time converts dates and timestamps alone). :read names what a ReadableColumn extension returns instead: a :pg/type's schema, {:array :vector} for arrays as vectors of their elements, {:json :parsed} for json as the data the registry shapes.
A column's schema (without NULL) as PostgreSQL's JDBC driver returns it through next.jdbc:
dates and timestamps under :time (inst? by default), an array a java.sql.Array, json and
jsonb a PGobject, an interval a PGInterval, citext, bit(n > 1) and bit varying a PGobject
(these :any); real a Float, bit(1) a Boolean, numeric a Double for NaN, time and timetz a
java.sql.Time under every :time (next.jdbc.date-time converts dates and timestamps alone).
:read names what a ReadableColumn extension returns instead: a :pg/type's schema,
{:array :vector} for arrays as vectors of their elements, {:json :parsed} for json as the
data the registry shapes.(row-entry k inner nullable? opts)(row-entry k props inner nullable? {:keys [nil-columns]})A row map's entry for a column read as inner: NULL a [:maybe], or the key absent under :nil-columns :absent (next.jdbc.optional).
A row map's entry for a column read as inner: NULL a [:maybe], or the key absent under :nil-columns :absent (next.jdbc.optional).
(row-key table column {:keys [qualified? kebab? lower?] :or {qualified? true}})The key next.jdbc gives a column: qualified by its table when the column has one, unless :qualified? is false; table is [schema name], or "schema.table" split at its first dot; kebab-cased (:kebab?) or lower-cased (:lower?) as its builders do it.
The key next.jdbc gives a column: qualified by its table when the column has one, unless :qualified? is false; table is [schema name], or "schema.table" split at its first dot; kebab-cased (:kebab?) or lower-cased (:lower?) as its builders do it.
(transformer)(transformer {:keys [zone] :or {zone (java.time.ZoneId/systemDefault)}})Decodes JDBC and string values into the registry's types: java.sql.Timestamp and java.util.Date -> Instant, java.sql.Date -> LocalDate, an Instant or java.util.Date landing in a date or timestamp (without time zone) column is read in :zone, default the JVM's; JSON text in a json or jsonb column is parsed.
Decodes JDBC and string values into the registry's types: java.sql.Timestamp and java.util.Date -> Instant, java.sql.Date -> LocalDate, an Instant or java.util.Date landing in a date or timestamp (without time zone) column is read in :zone, default the JVM's; JSON text in a json or jsonb column is parsed.
(write-type schema {:keys [write time] :or {time :inst} :as opts})A column's schema (without NULL) as an argument the driver takes: :write names what a SettableParameter extension sends for a :pg/type; a date or timestamp a java.util.Date or the java.time type pgjdbc takes (LocalDate, LocalDateTime, OffsetDateTime); an array column's argument is an array of its elements' (array-type); otherwise the types read-type shares with it (:time extends both sides).
A column's schema (without NULL) as an argument the driver takes: :write names what a SettableParameter extension sends for a :pg/type; a date or timestamp a java.util.Date or the java.time type pgjdbc takes (LocalDate, LocalDateTime, OffsetDateTime); an array column's argument is an array of its elements' (array-type); otherwise the types read-type shares with it (:time extends both sides).
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |