On Tue, 12 Oct 1999, Kevin Heflin wrote:
>
> Just trying to get a handle on how to work with an array as a datatype.
>
> For exampel I set up a table:
>
> name varchar (20),
> ageids int4[]
>
>
> Made an INSERT like:
>
> insert into TABLENAME (name, ageids) values ('test', '{1, 2, 3, 4}');
>
>
> What I haven't been able to figure out is how to do a select where one of
> the ageids = a particular number.
>
>
> I'd like to do something like
> select * from tablename where ( any ageids = 3 )
See the PostgreSQL contrib and array operators in this section.
Example *=, **= ..etc.
select * from tablename where ageids *= 3;
Zakkr