Re: shortcut for select * where id in (arrayvar) - Mailing list pgsql-general

From Tom Lane
Subject Re: shortcut for select * where id in (arrayvar)
Date
Msg-id 8157.1206927652@sss.pgh.pa.us
Whole thread Raw
In response to shortcut for select * where id in (arrayvar)  (Ivan Sergio Borgonovo <mail@webthatworks.it>)
Responses Re: shortcut for select * where id in (arrayvar)
List pgsql-general
Ivan Sergio Borgonovo <mail@webthatworks.it> writes:
> for _row in
>     select err, msg from errortable where err in (errcode)

> where errcode is an array.
> That syntax doesn't work...

In recent PG releases it will work as "WHERE err = ANY (errcode)"
but note that there is *no* guarantee that the select will deliver
the rows in the same order the array elements are in.

            regards, tom lane

pgsql-general by date:

Previous
From: brian
Date:
Subject: Re: shortcut for select * where id in (arrayvar)
Next
From: "Amit Phatarphekar"
Date:
Subject: Logging/Viewing parameters of a prepared statement