On Wed, Jul 30, 2008 at 04:45:47PM +0900, ITAGAKI Takahiro wrote:
> Here is a patch to copy column storage parameters and reloptions on
> CREATE TABLE LIKE, which I proposed at:
> [HACKERS] Uncopied parameters on CREATE TABLE LIKE
> http://archives.postgresql.org/message-id/20080724145954.E572.52131E4D@oss.ntt.co.jp
>
> Column storage parameters (by ALTER COLUMN SET STORAGE) and table
> storage parameters (by ALTER TABLE SET (...) ) are copied from template
> tables on LIKE or parent tables on INHERITS (1. and 2. at above e-mail).
> The patch does not include copying of comments (3.) for now.
> It also includes new regression tests and rough documentation.
>
> When template or parent tables have non-default settings,
> they are copied into a new table automatically on CREATE TABLE.
> If CREATE TABLE statement has own storage parameter definition,
> they overwrites inherited settings.
I'd like to have the ability to copy these parameters, but not to have it
be automatic. Some of my clients applications commonly use CREATE TABLE
LIKE to get empty work tables to populate and update before adding the
data to the main table (which may have non-default settings). The automatic
behaviour may be undesirable for this use.
-dg
--
David Gould daveg@sonic.net 510 536 1443 510 282 0869
If simplicity worked, the world would be overrun with insects.