Example code from docs for adding indices doesn't work

I'm using the example code from https://orm.drizzle.team/docs/indexes-constraints#indexes (screenshot #1) To create an index, but the generated migration and SQL don't have any corresponding index creation code (screenshot #2) I generate the migration using
npx drizzle-kit generate:pg --schema db/schema/schema.ts --out db/migrations
npx drizzle-kit generate:pg --schema db/schema/schema.ts --out db/migrations
Drizzle ORM - next gen TypeScript ORM
Drizzle ORM is a lightweight and performant TypeScript ORM with developer experience in mind.
No description
No description
1 Reply
jackpu
jackpuOP11mo ago
The problem was that auto-completion in VSCode imported index /uniqueIndex methods from mysql-core instead of pg-core
Want results from more Discord servers?
Add your server