Releases: seancorfield/next-jdbc
Release 1.0.7
Documentation:
- Adds a Tips & Tricks section to Friendly SQL Functions with database-specific suggestions, that starts with using
ANY(?)
and arrays in PostgreSQL forIN (?,,,?)
style queries (for which there's a new test as well!). - Clarifies that JDBC URL strings should start with
jdbc:
(and note thatclojure.java.jdbc
allowed this to be omitted). - Clarifies use of
:username
with HikariCP. - Fixes numerous typos and formatting glitches.
Simplification:
- Fixes #60 by supporting simpler
:schema
entry formats::table/column
is equivalent to the old[:table :column :one]
and[:table/column]
is equivalent to the old[:table :column :many]
. The older formats will continue to be supported but should be considered deprecated.
Release 1.0.6
Bug Fixes:
- Fix #52 by using a US-locale function in the "lower" result set builders to avoid unexpected character changes in column names in locales such as Turkish. If you want the locale-sensitive behavior, pass
clojure.string/lower-case
into one of the "modified" result set builders. This mirrors recent changes inhoneysql
andclojure.java.jdbc
.
Enhancements:
- Add
next.jdbc.result-set/as-maps-adapter
andnext.jdbc.result-set/as-arrays-adapter
to provide a way to override the default result set reading behavior of using.getObject
.
Documentation:
- Fix #54 by improving documentation around data type conversions (and the
ReadableColumn
andSettableParameter
protocols). - Improved documentation around
insert-multi!
andexecute-batch!
.
Housekeeping:
- Update
org.clojure/test.check
to"0.10.0"
.
Release 1.0.5
The "mapified" result set used by plan
now implements IPersistentMap
fully. This fixes #51 by adding support for dissoc
(as well as cons
, count
, empty
, etc).
The documentation around connection pooling has also been improved, based on feedback from users.
Release 1.0.4
Documentation improvements. Increased test coverage (embedded PostgreSQL). Repackage the JAR to satisfy cljdoc.org.
Release 1.0.3
Adds next.jdbc.connection/->pool
to make it easier to set up connection pooling with HikariCP and c3p0. The Getting Started documentation shows how to use both libraries.
Documentation improvements continue, including examples of extending ReadableColumn
and SettableParameter
.
Release 1.0.2
Overview:
- Adds support for batched execution of prepared statements:
next.jdbc.prepare/execute-batch!
. - Improves support for using unknown databases, especially local databases.
- Improves error reporting in
next.jdbc.sql
. - Lots of documentation and docstring improvements!
Enhancements:
- Fix #47 by exposing
next.jdbc.connect/dbtypes
as a table of known database types and aliases, along with their class name(s), port, and other non-default JDBC string components. JDBC URL assembly is now controlled entirely based on this single hash map. - Fix #46 by allowing
:host
to be:none
which tellsnext.jdbc
to omit the host/port section of the JDBC URL, so that local databases can be used with:dbtype
/:classname
for database types thatnext.jdbc
does not know. Also added:dbname-separator
and:host-prefix
to the "db-spec" to allow fine-grained control over how the JDBC URL is assembled. - Fix #45 by adding TimesTen driver support.
- Fix #44 so that
insert-multi!
with an emptyrows
vector returns[]
. - Fix #40 by adding
next.jdbc.prepare/execute-batch!
. - Added
assert
s innext.jdbc.sql
as more informative errors for cases that would generate SQL exceptions (from malformed SQL).
Changes to the (optional) specs:
- Fix #43 by adjusting the spec for
insert-multi!
to "require less" of thecols
androws
arguments. - Fix #42 by adding specs for
execute-batch!
andset-parameters
innext.jdbc.prepare
. - Added spec for
:order-by
to reflect what is actually permitted.
Documentation improvements:
- Fix #41 by improving docstrings and documentation, especially around database types and also around prepared statement handling.
Release 1.0.1
Bug fix:
- Fix #36 by adding a type hint for the
Connection
argument in thewith-transaction
macro.
Changes to the (optional) specs:
- Fix #37 by adjusting the spec for
with-transaction
to "require less" of the:binding
vector so the spec matches the function, allowing the options map to be omitted. - Fix #33 by updating the spec for the example
key-map
infind-by-keys
,update!
, anddelete!
to reflect that you cannot pass an empty map to these functions (and added tests to ensure the calls fail with spec errors).
Documentation improvements:
Release 1.0.0 "gold"
Two small usability additions over the Release Candidate:
- Address #31 by making
reify
'd objects produce a more informative string representation if they are printed (e.g., misusingplan
by not reducing it or not mapping an operation over the rows). - Fix #26 by exposing
next.jdbc.result-set/datafiable-result-set
so that variousjava.sql.DatabaseMetaData
methods that return result metadata information inResultSet
s can be easily turned into a fully realized result set. See Processing Database Metadata in the migration guide for an example.
Release 1.0.0 Release Candidate 1
Fix reflection warnings; add more flexibility to result set builders.
- Fix #24 by adding return type hints to
next.jdbc
functions. - Fix #22 by adding
next.jdbc.optional
with six map builders that omitNULL
columns from the row hash maps. - Documentation improvements (#27, #28, and #29), including changing "connectable" to "transactable" for the
transact
function and thewith-transaction
macro (for consistency with the name of the underlying protocol). - Fix #30 by adding
modified
variants of column name functions and builders. Thelower
variants have been rewritten in terms of these newmodified
variants. This adds:label-fn
and:qualifier-fn
options that mirror:column-fn
and:table-fn
for row builders.
Release 1.0.0 Beta 1
The first Beta release -- only accretive/fixative changes from now on.
- Set up CircleCI testing (just local DBs for now).
- Address #21 by adding
next.jdbc.specs
and documenting basic usage. - Fix #19 by caching loaded database driver classes.
- Address #16 by renaming
reducible!
toplan
(BREAKING CHANGE!). - Address #3 by deciding to maintain this library outside Clojure Contrib.