Alvaro Herrera <alvherre(at)commandprompt(dot)com> writes:
> tkarlik(at)ultimo(dot)pl wrote:
>> Without casting function executes much slower:
> If you're looking for a speedy answer, try a SQL function, not plpgsql.
He's still going to need the cast to name. It's not a bug, it's just
how things work: the indexes on pg_class support name = name equality
tests, not text = text.
regards, tom lane