Re: slow information schema with thausand users, seq.scan pg_authid - Mailing list pgsql-hackers

From Andrew - Supernews
Subject Re: slow information schema with thausand users, seq.scan pg_authid
Date
Msg-id slrnduemc1.2k35.andrew+nonews@atlantis.supernews.net
Whole thread Raw
In response to slow information schema with thausand users, seq.scan pg_authid  ("Pavel Stehule" <pavel.stehule@hotmail.com>)
Responses Re: slow information schema with thausand users, seq.scan pg_authid
Re: slow information schema with thausand users, seq.scan pg_authid
List pgsql-hackers
On 2006-02-06, Peter Eisentraut <peter_e@gmx.net> wrote:
> I suggest that your problem is the join order (unless you have 500000 
> tables as well).  Moreover, using left joins instead of inner joins 
> seems to be quite useless unless you plan to have tables that are not 
> owned by anyone and are not in a schema.

Perhaps you missed the fact that the query was not one that he wrote,
but is the query that psql uses for \ds ?

>> there is any possibility creating index for pg_authid?
>
> It already has indexes.

True, but they're not being used where you'd expect. This seems to be
something to do with the fact that it's not pg_authid which is being
accessed, but rather the view pg_roles.

-- 
Andrew, Supernews
http://www.supernews.com - individual and corporate NNTP services


pgsql-hackers by date:

Previous
From: Peter Eisentraut
Date:
Subject: Re: slow information schema with thausand users, seq.scan pg_authid
Next
From: "Mark Woodward"
Date:
Subject: Re: Shared memory and memory context question