Re: Is it possible to speed up addition of "not null"?

From: Florian Weimer <fweimer(at)bfk(dot)de>
To: depesz(at)depesz(dot)com
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Is it possible to speed up addition of "not null"?
Date: 2012-02-02 14:08:51
Message-ID: 82sjit2uq4.fsf@mid.bfk.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

* hubert depesz lubaczewski:

> I tried with some indexes, but I can't get the time to something
> reasonable, so here is my question: is there any way I could make the
> "not null" constraint *fast*?

You coul patch pg_attribute directly. I'm not sure if that's still safe
in current versions, though.

--
Florian Weimer <fweimer(at)bfk(dot)de>
BFK edv-consulting GmbH http://www.bfk.de/
Kriegsstraße 100 tel: +49-721-96201-1
D-76133 Karlsruhe fax: +49-721-96201-99

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Florian Weimer 2012-02-02 14:11:55 Re: Puzzling full database lock
Previous Message Merlin Moncure 2012-02-02 14:03:05 Re: Puzzling full database lock