Re: Index of a table is not used (in any case)

From: marc(at)oscar(dot)eng(dot)cv(dot)net (Marc Spitzer)
To: pgsql-sql(at)postgresql(dot)org
Subject: Re: Index of a table is not used (in any case)
Date: 2001-10-23 13:28:47
Message-ID: slrn9tas6u.2m3v.marc@oscar.eng.cv.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-sql

In article <web-490372(at)davinci(dot)ethosmedia(dot)com>, Josh Berkus wrote:
> Reinier,
>
> For future notice, [SQL] is the correct list for this kind of inquiry.
> Please do not post it to [HACKERS]. And please don't cross-post ... it
> results in a lot of needless duplication of effort.
>
>> I have defined a table and the necessary indices.
>
>> Is the order of index creation relevant? I.e., should I create the
>> indices before inserting
>> entries or the other way around?
>
> Ummm ... not to be obvious, or anything, but did you VACCUUM ANALYZE
> after populating your table?
>
> There's also some special steps to take if you are regularly deleting
> large numbers of records.

Could you tell me what those steps are or where to find them? I have
a db that I delete about 1 million records a day from in a batch job.
The only special thing I do is every few days I reindex the table
involved to reclame the space burned by the indexes not reclaiming
space on deletion of rows. What other good and useful things could I
do?

Thanks

marc

>
> -Josh
>
> ______AGLIO DATABASE SOLUTIONS___________________________
> Josh Berkus
> Complete information technology josh(at)agliodbs(dot)com
> and data management solutions (415) 565-7293
> for law firms, small businesses fax 621-2533
> and non-profit organizations. San Francisco
>
> ---------------------------(end of broadcast)---------------------------
> TIP 4: Don't 'kill -9' the postmaster

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Bill Studenmund 2001-10-23 13:41:15 Proposed new create command, CREATE OPERATOR CLASS
Previous Message Doug McNaught 2001-10-23 13:01:59 Re: Index of a table is not used (in any case)

Browse pgsql-sql by date

  From Date Subject
Next Message Haller Christoph 2001-10-23 14:10:35 Re: pgsql embedded again!
Previous Message Doug McNaught 2001-10-23 13:01:59 Re: Index of a table is not used (in any case)