Hubert FONGARNAND <informatique.internet@fiducial.fr> writes:
> CREATE TABLE node
> (
> node_id character varying(36) NOT NULL ,
> node_trash integer NOT NULL DEFAULT 0,
> CONSTRAINT pk_node PRIMARY KEY (node_id)
> )
> WITH OIDS;
> select count(*)
> from NODE
> where NODE_ID
> in (select NODE_ID from NODE where NODE_TRASH=3D0 limit 1 offset 0)
OK, it seems the key bit here is that the IN's subselect has a
varchar(N) column ... you don't see the failure unless the subselect
result column has a nondefault typmod. So a possibly helpful workaround
until 8.2.1 comes out is to cast NODE_ID to text in the subselect.
Patch committed; thanks for the report!
regards, tom lane