Thread: select

select

From
"cristi"
Date:
I have an integer vector: 101,105,120... and a table with an integer field
named "cod" .
I want to select the records who contains in field named "cod" one of the
vector values.
How can I do that?

select * from table_name where cod = ????????





Re: select

From
Tom Lane
Date:
"cristi" <cristi@dmhi.ct.ro> writes:
> I have an integer vector: 101,105,120... and a table with an integer field
> named "cod" .
> I want to select the records who contains in field named "cod" one of the
> vector values.

SELECT * FROM table_name WHERE cod IN (101,105,120...);

            regards, tom lane