Tom Lane wrote: > It doesn't happen for me either. Looking at the planner code, it seems > like the relkind check should happen first because it'd be cheaper than > the OR condition. It is still unclear why the execution plan looks like that, but maybe it would be more robust to change "has_sequence_privilege" so that it just returns FALSE if the argument is not a sequence. Yours, Laurenz Albe