- Deprecated message
- Support
"exactOptionalPropertyTypes": true
by allowing undefined values ininsertItem
,insertItems
,updateItem
andupdateItems
.
- Chore: correctly deprecate Entity
- Chore: Fix links to Knex.js documentation.
- Chore: package upgrades.
- Feature: Added bindings argument to
selectRaw
to utilize knex raw string bindings - Added
orWhereParentheses
- Feature: Added
getKnexQueryBuilder
. - Feature: Added extra parameter to
validateTables
to filter on specific tables.
- Fix: Use knex count return type. See getCount()
- Chore: package upgrade.
- Chore: CI tests 14.x, 16.x, 18.x.
- Chore: Remove tslint, add eslint.
- Bug: Correct
registerBeforeUpdateTransform
andregisterBeforeInsertTransform
calls.
- Chore: Use prepack script instead of prepublish.
- Chore: Properly deprecate mentions of "entity".
- Chore: Deprecate
primary
property of column. - Feature: Added
getSingleOrUndefined
andgetFirstOrUndefined
.
- Deprecation message for functions using the primary key:
findByPrimaryKey
,delByPrimaryKey
,updateItemByPrimaryKey
,updateItemsByPrimaryKey
.
- Bug (#51): Don't override query builder in
updateItemWithReturning
,insertItemWithReturning
,insertItems
andupdateItemsByPrimaryKey
.
- Bug: Export registerQueryBuilderExtension
- Bug: Export registerQueryBuilderExtension (NOT FIXED)
- Chore: Upgrade packages: Knex.js is now tested at v1.0.4
- Feature: registerQueryBuilderExtension
- Chore: use prettier
- Bug:
insertItemWithReturning
andupdateItemWithReturning
didn't use alias.
- Attach
tableMetadataKey
andtableColumns
references to theTable
class prototypes- This fixes a rare and unique issue where the same
Column
s andTable
s can get registered multiple times as a side-effect of overenthusiatic tree-shaking
- This fixes a rare and unique issue where the same
- Republish of 4.5.0 with correct /dist.
- Feature: added
updateItemWithReturning
. - Bug: not using database name on joined column names when using
innerJoinTableOnFunction
.
- Bug: result of
getFirstOrNull
andgetSingleOrNull
not always union withnull
.
- Feature: use
getColumn
inwhereColumn
in cases with nested subqueries.
- Feature: added
getColumnAlias
to get alias of column name to use inraw
functions. - Feature:
insertItemWithReturning
. - Feature:
distinctOn
.
- Bug:
where
didn't use alias of joined column.
- Added functions
innerJoin
andleftOuterJoin
.
- Upgrade Knex.js to v0.95.0.
- Upgrade TypeScript to v4.2.3.
- Fix example code for
registerBeforeInsertTransform
.
- Dropped lamba support.
- Return correct object(s) when omitting a select clause.
- Fix:
orderBy
withinnerJoinTableOnFunction
.
- Dropped support for Node 8 (Knex.js v0.21.0)
- Minimal TypeScript version is 4.1.
- Updated all functions to use strings as parameters and deprecated the use of lambas. Use
npx typed-knex -u string-parameters
to upgrade. - Better error message when there is a foreign key object, but not a foreign key property.
findByPrimaryKey
returns| undefined
instead of| void
.
- Allow
Date
columns inorderBy
.
- Documentation: registerBeforeInsertTransform and registerBeforeUpdateTransform.
- Allow Date columns in
findByPrimaryKey
. - Tested with Node.js v14.11.0.
- Added "Breaking changes in next major release" in README.
- Fixed insert and update queries for tables with column name mappings.
- Fixed compilation errors for sub-queries using
code
(whereExists
,union
,selectQuery
)
- Added
FlattenOption
to the default import. - Make
tableName
optional for@Table
.
- Fix
getCount
result.
- Fix: export
validateTables
. - Added
orderByRaw
.
- Fix: Table joined with
leftOuterJoinTableOnFunction
could not be referenced in a followingleftOuterJoinTableOnFunction
. - Add
Table
as alias forEntity
andvalidateTables
forvalidateEntities
.
- Added
insertSelect
for inserting selects (egINSERT INTO table (column) SELECT 'value'
)
- Updated on clauses for joins:
- Deprecated
.onColumns
. Usenpx typed-knex -u join-on-columns-to-on
to upgrade. - Added
.on
,andOn
,orOn
,onVal
,andOnVal
,orOnVal
.
- Deprecated
- Add deprecation warning for
FlattenOption.noFlatten
.
- Updated support for
Date
to also include nullable values. - Added support for array type in entities.
- Added
getTableName
andgetColumnName
. - Added
keepFlat
. - Upgraded packages.
- Rewritten some internal helper types.
- Added support for
Date
type in entities.
- Overloaded
orWhere
andandWhere
as to also accept an operator. - Added
orWhereNull
andorWhereNotNull
.
- Added
innerJoinTableOnFunction
. - Overloaded
where
as to also accept an operator.
- Fix: better handling of optional properties.
- Added
selectQuery
.
Completely different interface, feels like I'm doing a Python 3.