The create table statement can be something like :
CREATE TABLE mytable
(
pkfield character varying(4) NOT NULL,
charfield character varying(1) NOT NULL DEFAULT 'A'::character varying,
intfield bigint NOT NULL DEFAULT 1,
CONSTRAINT mytable_pkey PRIMARY KEY (pkfield )
)
WITHOUT OIDS;
The expected default value :
- for charfield is "A" instead "'A'::character varying"
- for intfield is "1" and it is OK.
You can Test it using another DB adapter (eg mysql) with the correspondig create table:
CREATE TABLE mytable
(
pkfield varchar(4) NOT NULL,
charfield varchar(1) NOT NULL DEFAULT 'A'
intfield bigint NOT NULL DEFAULT 1,
CONSTRAINT mytable_pkey PRIMARY KEY (pkfield )
)
HTH,
blas
Is it possible if you can provide the CREATE table sql and the expected var_dump output of the descriptTable method?
That would help immensely as I am not an expert in the ways of pgsql
-ralph