Intersect and order by

From: Michaël Fiey <m(dot)fiey(at)futuresoundtech(dot)com>
To: <pgsql-general(at)postgresql(dot)org>
Subject: Intersect and order by
Date: 2001-02-28 18:01:53
Message-ID: 006b01c0a1b0$8c3b81c0$6400a8c0@pc03
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi,

I don't understand what's happening with my command
I read postgresql docs, it should work...What's the problem ?
The command is :

select col1
from table
where <conditions 1>
intersect
select col1
from table
where <conditions 2>
order by col1

It does not work and return "get_sortgroupclause_expr: ORDER/GROUP BY
expression not found in targetlist"

I use pgsql 7.03 ont redhat 7.0.

Any help would be appreciated

michael

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Bruce Momjian 2001-02-28 18:04:00 Re: Slowdown problem when writing 1.7million records
Previous Message jean-francois butkiewicz 2001-02-28 17:53:28 Newbie question about locks...