Re: [BUGS] BUG #4596: information_schema.table_privileges is way too slow

2008-12-25 Thread Tom Lane
Kirill Simonov writes: > Pavel Stehule wrote: >> really it's should be slow, it's cross join pg_class, pg_authid, pg_authid > Yes, I realize why it's slow. I'm introspecting the database schema, > that's why I need the whole contents of "table_privileges". I suppose I > could obtain the same

Re: [BUGS] BUG #4596: information_schema.table_privileges is way too slow

2008-12-25 Thread Kirill Simonov
Pavel Stehule wrote: really it's should be slow, it's cross join pg_class, pg_authid, pg_authid for fast respond you have to specify minimally table_name and grantor fields. select * from information_schema.table_privileges where table_name = 'foo' and grantor = 'pavel'; Yes, I realize why i

Re: [BUGS] BUG #4596: information_schema.table_privileges is way too slow

2008-12-25 Thread Kirill Simonov
Pavel Stehule wrote: 2008/12/25 Kirill Simonov : Tom Lane wrote: "Kirill Simonov" writes: It takes about 5 minutes to perform the query SELECT * FROM information_schema.table_privileges on an empty database (i.e. with system tables only). Not here. What non-default settings might you be usi

Re: [BUGS] BUG #4596: information_schema.table_privileges is way too slow

2008-12-25 Thread Pavel Stehule
Hello really it's should be slow, it's cross join pg_class, pg_authid, pg_authid for fast respond you have to specify minimally table_name and grantor fields. select * from information_schema.table_privileges where table_name = 'foo' and grantor = 'pavel'; regards Pavel Stehule 2008/12/25, Kir

Re: [BUGS] BUG #4596: information_schema.table_privileges is way too slow

2008-12-25 Thread Pavel Stehule
Really, this view is strange. I'll look on at Pavel 2008/12/25, Kirill Simonov : > Pavel Stehule wrote: >> 2008/12/25 Kirill Simonov : >>> Tom Lane wrote: "Kirill Simonov" writes: > It takes about 5 minutes to perform the query > SELECT * FROM information_schema.table_privileges >>>

Re: [BUGS] BUG #4596: information_schema.table_privileges is way too slow

2008-12-25 Thread Pavel Stehule
2008/12/25 Kirill Simonov : > Tom Lane wrote: >> >> "Kirill Simonov" writes: >>> >>> It takes about 5 minutes to perform the query >>> SELECT * FROM information_schema.table_privileges >>> on an empty database (i.e. with system tables only). >> >> Not here. What non-default settings might you be

Re: [BUGS] BUG #4596: information_schema.table_privileges is way too slow

2008-12-25 Thread Kirill Simonov
Tom Lane wrote: "Kirill Simonov" writes: It takes about 5 minutes to perform the query SELECT * FROM information_schema.table_privileges on an empty database (i.e. with system tables only). Not here. What non-default settings might you be using? Indeed, it is slow because there are a lot