Skip to content

Bump drizzle-orm from 0.27.2 to 0.28.2#5

Closed
dependabot[bot] wants to merge 1 commit intomainfrom
dependabot/npm_and_yarn/drizzle-orm-0.28.2
Closed

Bump drizzle-orm from 0.27.2 to 0.28.2#5
dependabot[bot] wants to merge 1 commit intomainfrom
dependabot/npm_and_yarn/drizzle-orm-0.28.2

Conversation

@dependabot
Copy link

@dependabot dependabot bot commented on behalf of github Aug 14, 2023

Bumps drizzle-orm from 0.27.2 to 0.28.2.

Release notes

Sourced from drizzle-orm's releases.

0.28.1

  • 🐛 Fixed Postgres array-related issues introduced by 0.28.0 (#983, #992)

0.28.0

Breaking changes

Removed support for filtering by nested relations

Current example won't work in 0.28.0:

const usersWithPosts = await db.query.users.findMany({
  where: (table, { sql }) => (sql`json_array_length(${table.posts}) > 0`),
  with: {
    posts: true,
  },
});

The table object in the where callback won't have fields from with and extras. We removed them to be able to build more efficient relational queries, which improved row reads and performance.

If you have used those fields in the where callback before, there are several workarounds:

  1. Applying those filters manually on the code level after the rows are fetched;
  2. Using the core API.

Added Relational Queries mode config for mysql2 driver

Drizzle relational queries always generate exactly one SQL statement to run on the database and it has certain caveats. To have best in class support for every database out there we've introduced modes.

Drizzle relational queries use lateral joins of subqueries under the hood and for now PlanetScale does not support them.

When using mysql2 driver with regular MySQL database - you should specify mode: "default". When using mysql2 driver with PlanetScale - you need to specify mode: "planetscale".

import { drizzle } from 'drizzle-orm/mysql2';
import mysql from 'mysql2/promise';
import * as schema from './schema';
const connection = await mysql.createConnection({
uri: process.env.PLANETSCALE_DATABASE_URL,
});
const db = drizzle(connection, { schema, mode: 'planetscale' });

Improved IntelliSense performance for large schemas

We've run the diagnostics on a database schema with 85 tables, 666 columns, 26 enums, 172 indexes and 133 foreign keys. We've optimized internal types which resulted in 430% speed up in IntelliSense.

... (truncated)

Commits
  • 038a74d Merge pull request #1014 from drizzle-team/release-0.28.2
  • 8c31aee Bump drizzle-typebox to 0.1.0
  • 3264daf The community contributions release
  • 25d729f Merge pull request #996 from Bulbang/feature/typebox-compatibility
  • 59c6dd4 Typebox compatibility
  • 964548a Merge pull request #1002 from balazsorban44/balazsorban44-patch-1
  • 2f1fc25 Merge branch 'main' into balazsorban44-patch-1
  • 3febe3c Merge pull request #884 from mosch/patch-2
  • 6d0499c Merge branch 'main' into patch-2
  • c1b07c8 Merge pull request #851 from jorgectf/jorgectf/add-codeql-workflow
  • Additional commits viewable in compare view

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

Bumps [drizzle-orm](https://github.com/drizzle-team/drizzle-orm) from 0.27.2 to 0.28.2.
- [Release notes](https://github.com/drizzle-team/drizzle-orm/releases)
- [Commits](drizzle-team/drizzle-orm@0.27.2...0.28.2)

---
updated-dependencies:
- dependency-name: drizzle-orm
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot bot added the dependencies Pull requests that update a dependency file label Aug 14, 2023
@dependabot @github
Copy link
Author

dependabot bot commented on behalf of github Aug 24, 2023

Superseded by #7.

@dependabot dependabot bot closed this Aug 24, 2023
@dependabot dependabot bot deleted the dependabot/npm_and_yarn/drizzle-orm-0.28.2 branch August 24, 2023 17:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants