© 2026 Hedgehog Software, LLC
await prisma.user.create({ name: 'John', posts: { createMany: newPosts } });
cosnt [{id: userId}] = await db.insert(users).values({ name: 'John' }).returning(); await db.insert(posts).values(newPosts.map(post => ({ ...post, userId })));
userId