const sqlite = new Database("db.sqlite");
const db = drizzle<typeof schema>(sqlite, { schema });
const books = new Array(35).fill({}).map((b, i) => ({
id: i.toString(),
title: "The Great Gatsby",
description: "A book about a rich guy",
}));
await db.insert(schema.books).values(books);
What version of
drizzle-orm
are you using?0.31.2
What version of
drizzle-kit
are you using?0.22.1
Describe the Bug
When running an
insert()
query with more than 32 values, D1 throws error:too many SQL variables at offset
.Expected behavior
Expect Drizzle to chunk the inserts similar to Prisma
Environment & setup