Download Latest Version Release 0.13.0.zip (402.8 kB)
Email in envelope

Get an email when there's a new version of Jennifer

Home / v0.12.0
Name Modified Size InfoDownloads / Week
Parent folder
README.md 2021-12-15 1.6 kB
Release 0.12.0.tar.gz 2021-12-15 241.9 kB
Release 0.12.0.zip 2021-12-15 384.0 kB
Totals: 3 Items   627.6 kB 0

In memory of my father - even with very low understanding in programming, he was always interested in the current state of Jennifer and whether it was useful to people

Changelog

General

  • add crystal 1.2.0 support

QueryBuilder

  • #pluck accepts splatted named tuple of desired attribute-type pairs and returns array of such tuples as a records
  • #upsert passes expression builder as a block argument

Model

  • add Optimistic locking support via macro with_optimistic_lock(column_name = lock_version)
  • updated_at and created_at fields aren't override on save if have been set manually
  • add upsert class method to insert multiple models while ignoring conflicts on specified unique fields

Adapter

  • fix database connection query arguments building
  • each adapter includes RequestMethods instead of including it by base adapter class
  • add a new upsert overload that allows passing a collection of Jennifer::Model::Base
  • fix insert_on_duplicates sql generation for postgres adapter if no unique fields given

SqlGenerator

  • any INSERT, UPDATE, SELECT and DELETE requests uses quoted tables/columns if they are created by QueryBuilder::ExpressionBuilder (raw SQL is placed as-is)
  • .select_clause uses specified query attributes to select and fall back to custom fields only if there is no custom attribute to select

Migration

  • TableBuilder::ChangeTable now performs DropForeignKey, DropIndex & DropReference before any column manipulation
  • fix TableBuilder::ChangeEnum to use specified adapter to query effected tables
Source: README.md, updated 2021-12-15