Skip site navigation (1) Skip section navigation (2)

Re: Unused indices

From: Shaun Thomas <sthomas(at)peak6(dot)com>
To: Greg Smith <greg(at)2ndquadrant(dot)com>
Cc: Benjamin Krajmalnik <kraj(at)servoyant(dot)com>,"pgsql-performance(at)postgresql(dot)org" <pgsql-performance(at)postgresql(dot)org>
Subject: Re: Unused indices
Date: 2011-02-24 19:36:32
Message-ID: 4D66B340.40307@peak6.com (view raw or flat)
Thread:
Lists: pgsql-performance
On 02/24/2011 12:13 PM, Greg Smith wrote:

> That's not quite the right filter.  You want to screen out
> everything that isn't a unique index, not just the primary key ones.
> You probably can't drop any of those without impacting database
> integrity.

Ah yes. I was considering adding the clause for unique indexes. Filthy 
constraint violations.

> Also, as a picky point, you really should use functions like
> pg_relation_size instead of doing math on relpages.

You know, I always think about that, but I'm essentially lazy. :) I 
personally haven't ever had the old *8 trick fail, but from your 
perspective of working with so many variations, I could see how you'd 
want to avoid it.

I'll be good from now on. ;)

-- 
Shaun Thomas
OptionsHouse | 141 W. Jackson Blvd. | Suite 800 | Chicago IL, 60604
312-676-8870
sthomas(at)peak6(dot)com

______________________________________________

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

In response to

pgsql-performance by date

Next:From: Dave CrookeDate: 2011-02-24 19:55:31
Subject: Picking out the most recent row using a time stamp column
Previous:From: Vik ReykjaDate: 2011-02-24 19:33:00
Subject: Re: Pushing IN (subquery) down through UNION ALL?

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group