9.1: Slow to add range check on indexed column

From: Moshe Jacobson <moshe(at)neadwerx(dot)com>
To: pgsql-general <pgsql-general(at)postgresql(dot)org>
Subject: 9.1: Slow to add range check on indexed column
Date: 2013-05-25 19:37:04
Message-ID: CAJ4CxLncTg50cfkjz6=pwFx10jf0xyGatFmk2teodYRn6u17WA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

I just created a new partition in a log table, and then built a check
constraint on the recorded timestamp column.

I have an index on this column, but the adding of the check constraint took
a very, very long time.

It seems that PostgreSQL 9.1 does not check the index when building a check
constraint on an indexed column. Is this correct? Is this addressed in
future releases?

Thanks.

--
Moshe Jacobson
Nead Werx, Inc. | Manager of Systems Engineering
2323 Cumberland Parkway, Suite 201 | Atlanta, GA 30339
moshe(at)neadwerx(dot)com | www.neadwerx.com

"Quality is not an act, it is a habit." -- Aristotle

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Raymond O'Donnell 2013-05-25 20:18:31 Re: 9.1: Slow to add range check on indexed column
Previous Message Szymon Guz 2013-05-25 16:19:51 Re: Random numbers