pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
Indexing behavior
2+ messages / 2 participants
[nested] [flat]

* Indexing behavior
@ 2001-10-02 16:47 Josh Berkus <josh@agliodbs.com>
  2001-10-05 00:49 ` Re: Indexing behavior Ross J. Reedstrom <reedstrm@rice.edu>
  0 siblings, 1 reply; 2+ messages in thread

From: Josh Berkus @ 2001-10-02 16:47 UTC (permalink / raw)
  To: pgsql-sql

Folks,

Q: Are brand-new rows included in PostgreSQL indexed immediately?

Detail: I have several "keyset holding" tables where lists of primary
key ids are inserted for immediate retrieval by the user.  After a few
retrievals, these keysets are not used again.  The purpose of this
arrangement is to get around the fact that Postgres 7.1.2 does not have
recordset-returning procedures/functions.
       Since these keyset tables contain only brand new and deleted
rows, the only way that indexes on the keyset columns will be useful is
if the new rows are added to indexes immediately by the PostgreSQL
engine.  Otherwise, such indexes are useless and may even slow down
queries.   
       Feedback? Answers?

-Josh



______AGLIO DATABASE SOLUTIONS___________________________
                                       Josh Berkus
  Complete information technology      josh@agliodbs.com
   and data management solutions       (415) 565-7293
  for law firms, small businesses        fax 621-2533
    and non-profit organizations.      San Francisco



^ permalink  raw  reply  [nested|flat] 2+ messages in thread

* Re: Indexing behavior
  2001-10-02 16:47 Indexing behavior Josh Berkus <josh@agliodbs.com>
@ 2001-10-05 00:49 ` Ross J. Reedstrom <reedstrm@rice.edu>
  0 siblings, 0 replies; 2+ messages in thread

From: Ross J. Reedstrom @ 2001-10-05 00:49 UTC (permalink / raw)
  To: pgsql-sql

On Tue, Oct 02, 2001 at 09:47:09AM -0700, Josh Berkus wrote:
> Folks,
> 
> Q: Are brand-new rows included in PostgreSQL indexed immediately?
> 

 A: Yes, and that's why you don't add indices willy-nilly to all possible
column combos on any given table: INSERTs get real slow.

Ross



^ permalink  raw  reply  [nested|flat] 2+ messages in thread


end of thread, other threads:[~2001-10-05 00:49 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2001-10-02 16:47 Indexing behavior Josh Berkus <josh@agliodbs.com>
2001-10-05 00:49 ` Ross J. Reedstrom <reedstrm@rice.edu>

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