If you have constants and only 2 then auth.uid() = u_one OR auth.uid() = u.two. You probably could also use auth.uid() IN (u_one, u_two)
d
DanMossa
05/29/2022, 1:32 AM
Beautiful. It's the same thing as a normal check then
g
garyaustin
05/29/2022, 1:42 AM
RLS policy is just an added WHERE statement returning true or false/null. You can use selects on other tables, functions, etc... just need to think about performance though if you get complicated as it will run on each row during a select policy.