postgrest-js
postgrest-js copied to clipboard
Support bulk update with array of partial items
I am able to bulk update items (even without a filter) with an array of partial items.
Works fine but I had to cast my values .update(values as unknown as Partial<T>)
while they are actually Partial<T>[]
.
Looking in the source code, it seems like update
accept only a value at a time.
Does this work with @supabase/postgrest-js@rc
or @supabase/supabase-js@rc
? We'll be releasing these as new versions soon.
@soedirgo Haven't test with @supabase/postgrest-js@rc
. I used @supabase/postgrest-js
latest release.
~Actually, rereading this again, does bulk update actually work for you right now? AFAIK this is still a WIP upstream: https://github.com/PostgREST/postgrest/issues/1959~
~cc @steve-chavez~
I should've looked more closely :) from the same issue: https://github.com/PostgREST/postgrest/issues/1959#issuecomment-925385920
So bulk update is actually not supported atm.
Thought we had an issue tracking this - sorry about that! I'll repurpose this issue to track the bulk update feature.
Closing in favor of https://github.com/supabase/postgrest-js/issues/174