0.39.0
📦 drizzle-ormView on GitHub →
✨ 5 features🐛 5 fixes🔧 10 symbols
Summary
This release introduces support for the Bun SQL driver and expands CTE capabilities to include write operations and raw SQL. It also adds Neon Identity schema helpers and resolves several type-related bugs in drizzle-zod.
Migration Steps
- To use the new Bun driver, import drizzle from 'drizzle-orm/bun-sql'.
- If using Bun SQL, ensure you are on Bun v1.2.0+ and be aware of current limitations regarding concurrent statements and specific data types (JSON, Date, Arrays).
✨ New Features
- Added support for the Bun SQL driver (introduced in Bun v1.2.0).
- CTE (WITH) clauses now support INSERT, UPDATE, DELETE, and raw SQL templates.
- Added pre-defined 'neon_identity' schema and 'users_sync' table in the '/neon' import.
- Added 'getViewName' utility function to retrieve the name of a view or materialized view.
- Added Type Coercion support in drizzle-zod.
🐛 Bug Fixes
- Fixed issue where $count was undefined when using withReplicas.
- Fixed $count API error with vercel-postgres.
- Fixed schema.coerce issues when refining drizzle-zod types.
- Fixed 'excessively deep and possibly infinite types' in drizzle-zod.
- Fixed TypeScript error regarding inferred types needing references to internal drizzle-zod modules.
🔧 Affected Symbols
drizzle-orm/bun-sqldb.$withdb.withdrizzle-orm/neonusersSyncgetViewNamedrizzle-orm/sqlwithReplicas$countdrizzle-zod