Insert multiple rows return order

Is the return value of an "insert many" operation ordered in the same order of the items passed to it
const result = await db.insert(myTable).values([{id:1},{id:2}]).returning({ id: myTable.id })
const result = await db.insert(myTable).values([{id:1},{id:2}]).returning({ id: myTable.id })
Can I be sure that result[0] has id 1 and result[1] has id 2?
0 Replies
No replies yetBe the first to reply to this messageJoin
Want results from more Discord servers?
Add your server