Rafal Pietrak <rafal(at)zorro(dot)isa-geek(dot)com> writes:
> I thought trigger functions execute at root/postgres security level?
No. You probably want to make that function SECURITY DEFINER so it
executes as the owner, but this isn't default for triggers.
regards, tom lane