Contrib reindex script:

From: Shaun Thomas <sthomas(at)townnews(dot)com>
To: PostgreSQL general list <pgsql-general(at)postgresql(dot)org>
Subject: Contrib reindex script:
Date: 2002-05-07 13:47:46
Message-ID: Pine.LNX.4.44.0205070843420.16874-200000@hamster.lee.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

I modeled this after the vacuumdb script that is distributed in the
postgresql-base distribution. It can reindex a whole database, specific
tables, or just a single index. Being as we've had so much trouble with
things growing out of control, and the group seems to have tracked it
down to indexes, here it is.

I don't understand why we have a vacuumdb script, but not a reindex
script, considering the fact that vacuum doesn't clean up indexes.

Anyway, I didn't bother to comment it, I just copied vacuumdb and
changed relevant parts. It's not pretty, but it works. Maybe later
I'll produce one that doesn't look like it was coughed up by a robot.

--
+-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-+
| Shaun M. Thomas INN Database Administrator |
| Phone: (309) 743-0812 Fax : (309) 743-0830 |
| Email: sthomas(at)townnews(dot)com AIM : trifthen |
| Web : www.townnews.com |
| |
| "Most of our lives are about proving something, either to |
| ourselves or to someone else." |
| -- Anonymous |
+-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-+

Attachment Content-Type Size
reindexdb text/plain 4.4 KB

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Francisco Reyes 2002-05-07 13:48:13 Re: Index usage vs large repetitions of key
Previous Message Tom Lane 2002-05-07 13:41:04 Re: Allow user to create tables