Re: Interesting CREATE TABLE AS misbehavior

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Stephen Frost <sfrost(at)snowman(dot)net>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Interesting CREATE TABLE AS misbehavior
Date: 2006-09-18 14:45:02
Message-ID: 27663.1158590702@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Stephen Frost <sfrost(at)snowman(dot)net> writes:
> I'd tend to agree that it seems like a bug but I'm a little mystified as
> to why an 'order by' would be desired (or allowed) for a 'create table as'
> at all. Allowing it seems to imply it has some meaning.

By that logic we should disallow CLUSTER, REINDEX, and a host of other
things that are meaningless according to the SQL data model ;-)

But if you want a plausible use-case, the combination of ORDER BY and
LIMIT certainly seems interesting and useful, even if each one alone
is debatable.

regards, tom lane

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Eisentraut 2006-09-18 14:47:22 Re: [PATCHES] Patch for UUID datatype (beta)
Previous Message Peter Eisentraut 2006-09-18 14:43:34 Re: dump encoding (was Re: 8.2 beta blockers)