RLS13 — a user holding a filtered and an unfiltered role gets the filtered role's predicate,
and that predicate reaches the SQL sent to the database.
The unit tests (entityInfo.rlsFilterCollection / rlsExemption) prove the collection logic with
hand-built permission objects. This pins the seams they mock away, on real permission rows:
the permission gate: Read is granted by the filtered role, and the unfiltered role's Create
grant is cancelled by its own Deny row (Deny subtracts from Allow);
the RLS reader: the unfiltered role grants no Read, so it must not exempt the user from the
read filter; exactly the one bound filter is collected;
the emitted SQL: a live RunView sends a statement that carries that exact clause.
RLS13 — a user holding a filtered and an unfiltered role gets the filtered role's predicate, and that predicate reaches the SQL sent to the database.
The unit tests (entityInfo.rlsFilterCollection / rlsExemption) prove the collection logic with hand-built permission objects. This pins the seams they mock away, on real permission rows: