Re: Truncate Triggers

From: David Fetter <david(at)fetter(dot)org>
To: Gregory Stark <stark(at)enterprisedb(dot)com>
Cc: Decibel! <decibel(at)decibel(dot)org>, Alvaro Herrera <alvherre(at)commandprompt(dot)com>, Simon Riggs <simon(at)2ndquadrant(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Truncate Triggers
Date: 2008-02-02 18:43:25
Message-ID: 20080202184325.GB4153@fetter.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, Jan 31, 2008 at 10:22:42AM +0000, Gregory Stark wrote:
>
> "Decibel!" <decibel(at)decibel(dot)org> writes:
>
> > CLUSTER isn't DDL. Most forms of ALTER TABLE are. And CREATE blah,
> > etc.
>
> Fwiw I would call CLUSTER DDL. Note that it does make a change
> that's visible in the table definition afterwards.
>
> There are plenty of DDL commands which modify data (CREATE INDEX,
> ATLER TABLE ALTER COLUMN TYPE). The defining characteristic of DDL
> is not that it doesn't modify the data but that it does modify the
> table definition.

Counter-example: ALTER TABLE ALTER COLUMN USING will almost certainly
modify data, but it's DDL nonetheless.

> By that definition CLUSTER is DDL and TRUNCATE is DDL if you look at
> the implementation rather than the user-visible effects.

I agree that both are more DDL-like than DML-like.

Cheers,
David.
--
David Fetter <david(at)fetter(dot)org> http://fetter.org/
Phone: +1 415 235 3778 AIM: dfetter666 Yahoo!: dfetter
Skype: davidfetter XMPP: david(dot)fetter(at)gmail(dot)com

Remember to vote!
Consider donating to Postgres: http://www.postgresql.org/about/donate

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2008-02-02 19:15:48 Re: configurability of OOM killer
Previous Message Florian Weimer 2008-02-02 18:14:59 Re: configurability of OOM killer