-- Each subquery re-triggered the other table's RLS, causing: -- infinite recursion detected in policy for relation "requests" -- (surfaces on the first authenticated SELECT of requests, e.g.
-- FROM within a policy ON organization_members → stack overflow in PostgreSQL. -- Solution: SECURITY DEFINER function that bypasses RLS for the membership check.
一些您可能无法访问的结果已被隐去。
显示无法访问的结果