From: | Peter Eisentraut <peter_e(at)gmx(dot)net> |
---|---|
To: | pgsql-hackers(at)postgresql(dot)org, dmitry(at)koterov(dot)ru |
Subject: | Re: Fast ALTER TABLE ... ADD COLUMN ... DEFAULT xxx? |
Date: | 2009-05-21 09:50:56 |
Message-ID: | 200905211250.57328.peter_e@gmx.net |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Thursday 21 May 2009 11:06:29 Dmitry Koterov wrote:
> 1. Store the DEFAULT flag directly in NULL BITMAP (add a bit to NULL bitmap
> not only for NULLable fields, but also for NOT NULL DEFAULT ... fields).
> 2. Add another bitmap for each tuple (DEFAULT bitmap). Bit value 0 means
> that there is a real value in a cell, 1 - that the value is default.
> 3. The same as (1), but always force default value to be 0 (or false or any
> other values with meaning "zero") and optimize only these cases.
It seems to me that these solutions would require everyone in the world to pay
the overhead of a few to many bits in every tuple to optimize what appears to
be a relatively rare circumstance after all. Doesn't seem worth it to me.
From | Date | Subject | |
---|---|---|---|
Next Message | Peter Eisentraut | 2009-05-21 10:08:55 | Re: Compiler warning |
Previous Message | Dmitry Koterov | 2009-05-21 08:06:29 | Fast ALTER TABLE ... ADD COLUMN ... DEFAULT xxx? |