Fwd: how to have 2 select creteria on one column? SOLVED - Mailing list pgsql-sql

From Michael Hoeller
Subject Fwd: how to have 2 select creteria on one column? SOLVED
Date
Msg-id 200509101841.17950.MichaelHoeller@t-online.de
Whole thread Raw
List pgsql-sql
Hello,

sometime you have to write a mail and your brain gets cleared...

select a.code 
from stamm a 
where 
a.skart in ( (select skart from stamm where code like '%k%') ) 
and a.code not like '%V%';

May be this is not nice but this brings back the list I have.  

Michael
Hello, 

I would like to select every row which has got in the column CODE a "k" 
but I want to exclude every "kV" -- may be it is due to the fact that 
it is Saturday and I work too long I don't get it.. I tried a 
subselect, union but I struggle with the two select creteria on one 
column.

Can some one help me -- hope this is not a too stupid question. Normally 
google is my friend but also there I did not find a solution.

Thanks a lot 
Michael

pgsql-sql by date:

Previous
From: Michael Hoeller
Date:
Subject: how to update with a join?
Next
From: MichaelHoeller@t-online.de
Date:
Subject: Re: how to update with a join?