Yes, using the `.batch([query_1, query_2])` function will use SQLite transactions under the hood so

Yes, using the
.batch([query_1, query_2])
function will use SQLite transactions under the hood so you can make sure both queries either commit or rollback. https://developers.cloudflare.com/d1/build-with-d1/d1-client-api/#dbbatch
edit: Oops, sorry, I thought you were talking about D1. But the same works for the DO by what Isaac mentioned.
Was this page helpful?