pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Shaun Thomas <sthomas@optionshouse.com>
To: AJ Weber <aweber@comcast.net>
To: pgsql-performance@postgresql.org <pgsql-performance@postgresql.org>
Subject: Re: how to improve perf of 131MM row table?
Date: Thu, 26 Jun 2014 09:37:24 -0500
Message-ID: <53AC3024.5040409@optionshouse.com> (raw)
In-Reply-To: <53AC2CC3.9060403@comcast.net>
References: <53AB2CB1.8080201@comcast.net>
	<53AB35CC.10202@optionshouse.com>
	<1801a5d4-c3f1-4c0c-9c2c-ffb9d7f723a3@email.android.com>
	<53AB4551.4070207@optionshouse.com>
	<53AC1F6E.4000700@comcast.net>
	<53AC28AF.1060500@optionshouse.com>
	<53AC2CC3.9060403@comcast.net>
List-Unsubscribe:  <mailto:majordomo@postgresql.org?body=unsub%20pgsql-performance>

On 06/26/2014 09:22 AM, AJ Weber wrote:

> I sent the details as identified by pgAdmin III.

Interesting. Either there is a bug in pgAdmin, or you're connecting to a 
different database that is missing the primary key. What is the EXPLAIN 
ANALYZE output if you execute the query you sent on a psql prompt?

>      "alf_node_pkey" PRIMARY KEY, btree (id) CLUSTER
> would indicate to me that there is a PK on alf_node table, it is on
> column "id", it is of type btree, and the table is clustered around that
> index.
>
> Am I reading this totally wrong?

No, that's right. But that wasn't in the SQL you sent. In fact, there's 
a lot of stuff missing in that output.

Try running the EXPLAIN ANALYZE using the same psql connection you used 
to retrieve the actual table structure just now. I suspect you've 
accidentally connected to the wrong database. If it's still doing the 
sequence scan, we'll have to dig deeper.

-- 
Shaun Thomas
OptionsHouse, LLC | 141 W. Jackson Blvd. | Suite 800 | Chicago IL, 60604
312-676-8870
sthomas@optionshouse.com

______________________________________________

See http://www.peak6.com/email_disclaimer/ for terms and conditions related to this email


-- 
Sent via pgsql-performance mailing list (pgsql-performance@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-performance



view thread (25+ messages)  latest in thread

Message-ID: <53AC3024.5040409@optionshouse.com>
Permalink:  ../53AC3024.5040409@optionshouse.com/
Also on:    postgresql.org/message-id/53AC3024.5040409@optionshouse.com

 · 

reply

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: sthomas@optionshouse.com, aweber@comcast.net
  Subject: Re: how to improve perf of 131MM row table?
  In-Reply-To: <53AC3024.5040409@optionshouse.com>

* 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