Join Discord
Powered by
Hi guys I'm new to supabase, a quick question: is ...
# help
r
Riven
08/11/2021, 8:11 AM
Hi guys I'm new to supabase, a quick question: is there a transaction insert using supabase API? I cant seem to find it anywhere in the docs. Thanks!
s
Steve
08/11/2021, 4:02 PM
Every supabase-js insert is ran inside a transaction, so if an error happens(like a constraint failure) the transaction will be rolled back.
Steve
08/11/2021, 4:03 PM
If you wish to group inserts on different tables inside a single transaction, for now the way to do it would be through RPC:
https://supabase.io/docs/reference/javascript/rpc
Previous
Next