From: Alvaro Herrera <alvherre@commandprompt.com>
To: Y Sidhu <ysidhu@gmail.com>
Cc: pgsql-performance@postgresql.org
Subject: Re: How to Run a pg_stats Query
Date: Tue, 15 May 2007 18:50:29 -0400
Message-ID: <20070515225029.GU12731@alvh.no-ip.org> (raw)
In-Reply-To: <b09064f30705151542w4c88298l1d5aa0a8a170bd50@mail.gmail.com>
References: <b09064f30705151542w4c88298l1d5aa0a8a170bd50@mail.gmail.com>
Y Sidhu escribió:
> I turned on all the stats in the conf file (below) and restarted the server.
> Question is, what's the name of the database and how do I run a simple
> select query?
>
> stats_start_collector = true
> stats_command_string = true
> stats_block_level = true
> stats_row_level = true
> stats_reset_on_server_start = true
Stats are present on all databases. As for the name of the tables, try
pg_stat_user_tables and pg_stat_activity for starters. There are a lot
more; check the documentation or a \d pg_stat* in psql.
--
Alvaro Herrera http://www.CommandPrompt.com/
PostgreSQL Replication, Consulting, Custom Development, 24x7 support
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-performance@postgresql.org
Cc: alvherre@commandprompt.com, ysidhu@gmail.com
Subject: Re: How to Run a pg_stats Query
In-Reply-To: <20070515225029.GU12731@alvh.no-ip.org>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox