Have I got inserts right for MySQL(Planetscale)?
I'm switching over to Drizzle from Prisma, just wanted to make sure I have inserts written correctly, specifically inserts with relationships, for example, this is inserting a business with an associated businessAddress, does that look right? Ctx is just TRPC.
Appreciate the input, thanks.
1 Reply
If businessId is anything but an auto_increment, then this is correct
If it was an autoincrement field, then you can get it back from the insert query result