Search Postgresql Archives

problem with array query

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Folks

According to the 8.3 docs I should be able to write:
select * from tblretrain where   'ms-ap-t2-02c9' NOT IN   (owners);

where owners is an array per the following definition

CREATE TABLE tblretrain
(
  pkretrainid integer NOT NULL,
  mailid integer NOT NULL,
  train_to smallint NOT NULL,
  owners character varying(1024)[],
  bayes_trained boolean DEFAULT false,
  contents text NOT NULL,
  CONSTRAINT tblretrain_pk PRIMARY KEY (pkretrainid)
)

The problem is that it generates an error:

ERROR:  array value must start with "{" or dimension information
********** Error **********
ERROR: array value must start with "{" or dimension information
SQL state: 22P02

It seems as though postgres is not recognising owners as an array.

Any suggestions please ?
regards
Grant




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux