Skip to content

Releases: seancorfield/next-jdbc

Release 1.0.424

10 Apr 21:37
Compare
Choose a tag to compare
  • In Tips & Tricks, noted that MySQL returns BLOB columns as byte[] instead of java.sql.Blob.
  • Address #103, #104 by adding a section on timeouts to Tips & Tricks.
  • Fix #102 by allowing keywords or strings in :return-keys.
  • Fix #101 by tightening the spec on a JDBC URL to correctly reflect that it must start with jdbc:.
  • Add support for calling .getLoginTimeout/.setLoginTimeout on the reified DataSource returned by get-datasource when called on a hash map "db-spec" or JDBC URL string.
  • Documentation improvements based on feedback (mostly from Slack), including a section on database metadata near the end of Getting Started.

Release 1.0.409

16 Mar 22:29
Compare
Choose a tag to compare

Add support for MariaDB (as :dbtype "mariadb") via PR #100 (@green-coder).

Release 1.0.405

14 Mar 23:19
Compare
Choose a tag to compare

This release includes no code changes, just documentation updates:

  • Improve documentation around plan so reduce etc is more obvious.
  • Attempt to drive readers to cljdoc.org instead of the GitHub version (which is harder to navigate).

Release 1.0.395

02 Mar 21:50
Compare
Choose a tag to compare

Enhancement:

  • Add read-as-instant and read-as-local functions to next.jdbc.date-time to extend ReadableColumn so that SQL DATE and TIMESTAMP columns can be read as Java Time types.

Documentation:

  • Specifically call out PostgreSQL as needing next.jdbc.date-time to enable automatic conversion of java.util.Date objects to SQL timestamps for prepared statements (#95).
  • Split Tips & Tricks into its own page, with a whole new section on using JSON data types with PostgreSQL (#94 -- thank you @vharmain).

Maintenance:

  • Bump dependencies to latest.

Release 1.0.384

28 Feb 19:15
Compare
Choose a tag to compare

Bug fixes:

  • Fix #88 by using 1-arity keyword call when table name unavailable (or :qualifier-fn returns nil or an empty string); also allows :qualifier-fn function to be called on empty table name (so :qualifier-fn (constantly "qual") will now work much like clojure.java.jdbc's :qualifier "qual" worked).

Enhancements:

  • Improve Unknown dbtype exception message (to clarify that :classname is also missing, #90).
  • Address #89, #91 by making minor performance tweaks to next.jdbc.result-set functions.

Documentation:

  • Add PostgreSQL streaming option information to Tips & Tricks (#87).
  • Documentation improvements (including #85, #92, #93 -- datafiable-row).
  • Move to MAJOR.MINOR.COMMITS versioning scheme (1.0.384).

Release 1.0.13

30 Dec 00:24
Compare
Choose a tag to compare

Enhancements:

  • Adds next.jdbc.prepare/statement to create Statement objects with all the options available to prepare except :return-keys.
  • Adds a way to set arbitrary properties on Connection and Statement / PreparedStatement objects, post-creation. Note: this uses clojure.java.data and the Java reflection API under the hood. #82

Documentation:

  • Numerous clarifications based on feedback from folks on Slack!

Infrastructure:

  • Update org.clojure/java.data to 0.1.5 (for property setting).

Release 1.0.12

12 Dec 00:52
Compare
Choose a tag to compare

Bug Fix:

  • Fix #80 by avoiding the auto-commit restore after a failed rollback in a failed transaction.

Enhancement:

  • Address #81 by splitting the SQL-building functions out of next.jdbc.sql into next.jdbc.sql.builder.

Documentation:

  • Address #78 by documenting the :connectionInitSql workaround for HikariCP/PostgreSQL and non-default schemas.

Release 1.0.11

07 Dec 17:29
Compare
Choose a tag to compare

Bug Fix:

  • Fix #76 by avoiding conversions on java.sql.Date and java.sql.Timestamp.

Documentation:

  • Fix a few links.
  • Fix typos in a few docstrings.
  • Formatting tweaks for consistency.

Testing:

  • Add testing against Microsoft SQL Server (run tests with environment variables NEXT_JDBC_TEST_MSSQL=yes and MSSQL_SA_PASSWORD set to your local -- 127.0.0.1:1433 -- SQL Server sa user password; assumes that it can create and drop fruit and fruit_time tables in the model database).
  • Add testing against MySQL (run tests with environment variables NEXT_JDBC_TEST_MYSQL=yes and MYSQL_ROOT_PASSWORD set to your local -- 127.0.0.1:3306 -- MySQL root user password; assumes you have already created an empty database called clojure_test).
  • Bump several JDBC driver versions for up-to-date testing.

Release 1.0.10

15 Nov 03:13
Compare
Choose a tag to compare

Enhancements:

  • Fix #75 by adding support for java.sql.Statement to plan, execute!, and execute-one!.
  • Fix #73 by providing a new, optional namespace next.jdbc.date-time that can be required if your database driver needs assistance converting java.util.Date (PostgreSQL!) or the Java Time types to SQL timestamp (or SQL date/time).
  • Address #70 by adding CLOB & BLOB SQL Types to the Tips & Tricks section of Friendly SQL Functions and by adding next.jdbc.result-set/clob-column-reader and next.jdbc.result-set/clob->string helper to make it easier to deal with CLOB column data.

Documentation:

  • Fix link to All The Options in Migration from clojure.java.jdbc. PR #71 (@laurio).
  • Clarify what execute! and execute-one! produce when the result set is empty ([] and nil respectively, and there are now tests for this). Similarly for find-by-keys and get-by-id.
  • Add MS SQL Server section to Tips & Tricks to note that returns an empty string for table names by default (so table-qualified column names are not available). Using the :result-type (scroll) and :concurrency options will cause table names to be returned.
  • Clarify that Friendly SQL Functions are deliberately simple (hint: they will not be enhanced or expanded -- use plan, execute!, and execute-one! instead, with a DSL library if you want!).
  • Improve migration docs: explicitly recommend the use of a datasource for code that needs to work with both clojure.java.jdbc and next.jdbc; add caveats about column name conflicts (in several places).
  • Improve datafy/nav documentation around :schema.

Miscellaneous:

  • Address #74 by making several small changes to satisfy Eastwood.
  • Update org.clojure/java.data to "0.1.4" (0.1.2 fixes a number of reflection warnings).

Release 1.0.9

11 Oct 18:45
Compare
Choose a tag to compare

Enhancements:

  • Add next.jdbc.optional/as-maps-adapter to match next.jdbc.result-set/as-maps-adapter (this provides a way to override the default result set reading behavior of using .getObject when omitting SQL NULL values from result set maps).
  • Update the specs for the "db spec" hash map and some functions to reflect the addition of the :jdbcUrl option added in 1.0.8. #67

Documentation:

  • Expand documentation and some docstrings to clarify when to use execute-one! vs execute! vs plan. #69
  • Expand documentation around :next.jdbc/update-count to clarify that builder functions are not used (and so you won't get :update-count by specifying :builder-fn with an unqualified builder!). #68