Re: problematic query (for me ;-) [solved? - sorry to bother] - Mailing list pgsql-sql

From Kim Petersen
Subject Re: problematic query (for me ;-) [solved? - sorry to bother]
Date
Msg-id 3E660E0C.2020605@kyborg.dk
Whole thread Raw
In response to problematic query (for me ;-)  (Kim Petersen <kp@kyborg.dk>)
List pgsql-sql
Kim Petersen wrote:
> I'm trying to get a hint as to how i can solve this problem:

it seems it works to post to a newsgroup - i've been trying to solve 
this for hours - and just came up with a solution - only question now is 
whether or not it is usable (on millons of tuples).

select distinct t1.n,t2.n from test t1,test t2   where not exists     (select t from test where n=t1.n
intersect     select t from test where n=t2.n);
 

optimization ideas would be greatly appreciated.





pgsql-sql by date:

Previous
From: "speakeasy"
Date:
Subject: View - Join based on dis-similar data types
Next
From: luca.scaramella@recom.it
Date:
Subject: DELETE FROM A BLACK LIST