RLS with a join table
I can't for the life of me figure this one out 
I have a table of for
The
I need to setup RLS so that a user can read, instert, update, or delete a list if they have a
I'm assuming the correct order of operations when creating a new list is:
Let me know what additional info I can provide. Thanks!
I have a table of for
lists and a table for user_list_relations. The user_list_relations table is joined with the lists table via the list_id.The
user_list_relations table also has a column called user_profile_id which match the auth.uid().I need to setup RLS so that a user can read, instert, update, or delete a list if they have a
user_list_relation for that list.I'm assuming the correct order of operations when creating a new list is:
- Insert a new row for the list
- Create the user_list_relation using the list_id from the list that was just created.
Let me know what additional info I can provide. Thanks!