Skip site navigation (1) Skip section navigation (2)

Re: attoptions

From: Alex Hunsaker <badalex(at)gmail(dot)com>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: attoptions
Date: 2010-01-21 05:57:06
Message-ID: 34d269d41001202157n71d5fd6ajfdf27eb49672913c@mail.gmail.com (view raw or flat)
Thread:
Lists: pgsql-hackers
On Wed, Jan 20, 2010 at 19:51, Robert Haas <robertmhaas(at)gmail(dot)com> wrote:
> On Tue, Jan 19, 2010 at 10:51 AM, Alex Hunsaker <badalex(at)gmail(dot)com> wrote:
>> But yes, lets keep it simple for now.
>
> OK.  Updated patch attached.  Changes:
>
> - Incorporate your previous review patch.
> - Omit attacl and attoptions from hardcoded relation descriptor
> initializers so the whole thing still builds.

Seems to me a comment about the above might be nice.  Something like
/* Things after here are should always be default null */ in
pg_attribute.h ?

Other than the below it looks good to me.

*** a/src/backend/commands/tablecmds.c
--- b/src/backend/commands/tablecmds.c
***************
*** 2426,2437 **** ATPrepCmd(List **wqueue, Relation rel, AlterTableCmd *cmd,
  		case AT_SetOptions:		/* ALTER COLUMN SET ( options ) */
  		case AT_ResetOptions:	/* ALTER COLUMN RESET ( options ) */
  			ATSimplePermissionsRelationOrIndex(rel);
! 			ATSimpleRecursion(wqueue, rel, cmd, recurse);
  			pass = AT_PASS_COL_ATTRS;
  			break;
  		case AT_SetStorage:		/* ALTER COLUMN SET STORAGE */
  			ATSimplePermissions(rel, false);
! 			/* This command never recurses */
  			/* No command-specific prep needed */
  			pass = AT_PASS_COL_ATTRS;
  			break;
--- 2426,2437 ----
  		case AT_SetOptions:		/* ALTER COLUMN SET ( options ) */
  		case AT_ResetOptions:	/* ALTER COLUMN RESET ( options ) */
  			ATSimplePermissionsRelationOrIndex(rel);
! 			/* This command never recurses */
  			pass = AT_PASS_COL_ATTRS;
  			break;
  		case AT_SetStorage:		/* ALTER COLUMN SET STORAGE */
  			ATSimplePermissions(rel, false);
! 			ATSimpleRecursion(wqueue, rel, cmd, recurse);
  			/* No command-specific prep needed */
  			pass = AT_PASS_COL_ATTRS;
  			break;

In response to

Responses

pgsql-hackers by date

Next:From: Heikki LinnakangasDate: 2010-01-21 07:27:58
Subject: Re: HS/SR and smart shutdown
Previous:From: Takahiro ItagakiDate: 2010-01-21 03:56:20
Subject: Re: pgsql: Write a WAL record whenever we perform an operation without

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group