Laurent Martelli <laurent@aopsys.com> writes:
> The pictures table is scanned, but it's not needed.
Yes it is. For example, if pictures is empty then the view yields
zero rows. Omitting the join to pictures could give a different result.
regards, tom lane