INSERT/SELECT with ORDER BY
INSERT/SELECT with ORDER BY
От:
Bob Rivoir <rhr2@psu.edu>
Дата:
============================================================================
POSTGRESQL BUG REPORT TEMPLATE
============================================================================
Your name : Bob Rivoir
Your email address : rhr2@psu.edu
System Configuration
---------------------
Architecture (example: Intel Pentium) : AMD Athlon
Operating System (example: Linux 2.0.26 ELF) : OpenLinux eDesktop 2.4
PostgreSQL version (example: PostgreSQL-7.0): PostgreSQL-7.0.2
Compiler used (example: gcc 2.8.0) : gcc egcs-1.1.2 release
Please enter a FULL description of your problem:
------------------------------------------------
I got the following error message when I tried to do an INSERT using
SELECT ... ORDER BY:
ERROR: ORDER BY is not allowed in INSERT/SELECT
Please describe a way to repeat the problem. Please try to provide a
concise reproducible example, if at all possible:
----------------------------------------------------------------------
If you know how this problem might be fixed, list the solution below:
---------------------------------------------------------------------Re: INSERT/SELECT with ORDER BY
От:
Stephan Szabo <sszabo@megazone23.bigpanda.com>
Дата:
Unless I'm horribly misreading the spec, this is correct.
ORDER BY is used in reference to cursor definitions and
direct select statements, but is not part of query expressions
which is what the INSERT INTO references.
::=
INSERT INTO Re: INSERT/SELECT with ORDER BY
От:
Bruce Momjian <pgman@candle.pha.pa.us>
Дата:
> > Unless I'm horribly misreading the spec, this is correct. > ORDER BY is used in reference to cursor definitions and > direct select statements, but is not part of query expressions > which is what the INSERT INTO references. > > ::= > INSERT INTO
Re: INSERT/SELECT with ORDER BY
От:
Dirk Lutzebaeck <lutzeb@aeccom.com>
Дата:
Stephan Szabo writes: > > Unless I'm horribly misreading the spec, this is correct. > ORDER BY is used in reference to cursor definitions and > direct select statements, but is not part of query expressions > which is what the INSERT INTO references. > > ::= > INSERT INTO