Re: [HACKERS] PL/PgSQL for counting all rows in all tables.

2004-10-13 Thread Dave Page
-Original Message- From: Robert Treat [mailto:[EMAIL PROTECTED] Sent: 12 October 2004 21:21 To: Dave Page Cc: [EMAIL PROTECTED] Subject: Re: [HACKERS] PL/PgSQL for counting all rows in all tables. Maybe I didn't phrase that quite right. How would a user know that he needs

Re: [HACKERS] PL/PgSQL for counting all rows in all tables.

2004-10-12 Thread Dave Page
-Original Message- From: Robert Treat [mailto:[EMAIL PROTECTED] Sent: 11 October 2004 22:30 To: Dave Page Cc: [EMAIL PROTECTED] Subject: Re: [HACKERS] PL/PgSQL for counting all rows in all tables. How do you handle table growth that makes the reltuples value out of whack

Re: [HACKERS] PL/PgSQL for counting all rows in all tables.

2004-10-12 Thread Robert Treat
On Tuesday 12 October 2004 03:22, Dave Page wrote: -Original Message- From: Robert Treat [mailto:[EMAIL PROTECTED] Sent: 11 October 2004 22:30 To: Dave Page Cc: [EMAIL PROTECTED] Subject: Re: [HACKERS] PL/PgSQL for counting all rows in all tables. How do you handle table

Re: [HACKERS] PL/PgSQL for counting all rows in all tables.

2004-10-12 Thread Andreas Pflug
Robert Treat wrote: Right-click the table object and select 'Count' on the current versions. Previously, iirc it showed the message 'Refresh table to count' in the actual count field, so you did a right-click - Refresh. Maybe I didn't phrase that quite right. How would a user know that he needs

Re: [HACKERS] PL/PgSQL for counting all rows in all tables.

2004-10-12 Thread Rod Taylor
BTW The reason I'm asking about this is we're trying to come up with a good scheme for phppgadmin to show estimated counts without showing incorrect numbers to users... or at least giving them a clue that the numbers might be really off. The vacuum daemon should know how far off the count

Re: [HACKERS] PL/PgSQL for counting all rows in all tables.

2004-10-11 Thread Robert Treat
On Tue, 2004-10-05 at 05:09, Dave Page wrote: -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Ian FREISLICH Sent: 05 October 2004 09:57 To: Greg Sabino Mullane Cc: [EMAIL PROTECTED] Subject: Re: [HACKERS] PL/PgSQL for counting all rows

Re: [HACKERS] PL/PgSQL for counting all rows in all tables.

2004-10-05 Thread Ian FREISLICH
Greg Sabino Mullane wrote: ANALYZE; SELECT n.nspname, relname, reltuples FROM pg_class c, pg_namespace n WHERE c.relnamespace=n.oid AND relkind='r' AND NOT n.nspname ~ '^pg_' ORDER BY 1,2; Maybe this gem should be passed onto the pgadmin folks. When you click on a table name in the

Re: [HACKERS] PL/PgSQL for counting all rows in all tables.

2004-10-05 Thread Dave Page
-Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Ian FREISLICH Sent: 05 October 2004 09:57 To: Greg Sabino Mullane Cc: [EMAIL PROTECTED] Subject: Re: [HACKERS] PL/PgSQL for counting all rows in all tables. Greg Sabino Mullane wrote: ANALYZE

[HACKERS] PL/PgSQL for counting all rows in all tables.

2004-09-28 Thread David Fetter
Folks, I've noticed that when coming into an organization, I need to do some counting on what's in all the tables in a db. This shortens that process considerably, with the usual caveat that count(*) is a heavy operation. By the way, the 3 lines following godawful hack point to something

Re: [HACKERS] PL/PgSQL for counting all rows in all tables.

2004-09-28 Thread Greg Sabino Mullane
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 My version: ANALYZE; SELECT n.nspname, relname, reltuples FROM pg_class c, pg_namespace n WHERE c.relnamespace=n.oid AND relkind='r' AND NOT n.nspname ~ '^pg_' ORDER BY 1,2; - -- Greg Sabino Mullane [EMAIL PROTECTED] PGP Key: 0x14964AC8