pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Adam Erickson <adamre@cox.net>
To: pgsql-novice@postgresql.org
Subject: Aggregates and Indexes
Date: Fri, 2 Aug 2002 13:20:34 -0500
Message-ID: <ALEKKHACBIAEBNBPFKPCCEFHEDAA.adamre@cox.net> (raw)
In-Reply-To: <E2870D8CE1CCD311BAF50008C71EDE8E01F7494F@MAIL_EXCHANGE>

Their has been some discussion regarding aggregate functions and indexes.
It's clear that aggregate functions will not take advantage of any indexes.
(ie. SELECT sum(number) FROM table WHERE type=BLAH will not take advantage
of 'type' being indexed.)

I do a lot of reporting based on such SQL statements.  Counting rows from
large datasets.  Since the PG gurus don't seem to think this is such a big
deal can someone enlighten me as to why?

Thanks,
Adam Erickson




view thread (7+ messages)  latest in thread

Message-ID: <ALEKKHACBIAEBNBPFKPCCEFHEDAA.adamre@cox.net>
Permalink:  ../ALEKKHACBIAEBNBPFKPCCEFHEDAA.adamre@cox.net/
Also on:    postgresql.org/message-id/ALEKKHACBIAEBNBPFKPCCEFHEDAA.adamre@cox.net

 · 

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-sql@postgresql.org
  Cc: adamre@cox.net, pgsql-novice@postgresql.org
  Subject: Re: Aggregates and Indexes
  In-Reply-To: <ALEKKHACBIAEBNBPFKPCCEFHEDAA.adamre@cox.net>

* 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