error null value in column" concat_id" violates not-null constraint

From: Ana Louro <anaoliveiralouro(at)gmail(dot)com>
To: pgsql-sql(at)postgresql(dot)org
Subject: error null value in column" concat_id" violates not-null constraint
Date: 2010-11-25 15:58:25
Message-ID: 25a9e938-9841-436e-9546-ebeb6140de5d@z9g2000yqz.googlegroups.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Hi,
I'm just beggining in PostgreSql 9.0

I've created a table ,like this:

CREATE TABLE auxiliar
(
ano integer,
codigodc character varying,
id character varying,
concat_id character varying NOT NULL,
CONSTRAINT concat PRIMARY KEY (concat_id);

Now i want to insert values on concat_id resulting from a function
called "concat_id"

INSERT INTO concat_id

SELECT(concat_id) FROM auxiliar ;

I get "error null value in column"concat_id" violatres not null
constraint

Could anyone tell me what am i doing wrong?

Ana

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message Pavel Stehule 2010-11-26 07:45:28 Re: error null value in column" concat_id" violates not-null constraint
Previous Message Trinath Somanchi 2010-11-25 15:22:13 Re: insert from a select