Re: Wierd postgres Problem - Mailing list pgsql-sql

From Peter Eisentraut
Subject Re: Wierd postgres Problem
Date
Msg-id Pine.LNX.4.30.0102121714140.1100-100000@peter.localdomain
Whole thread Raw
In response to Wierd postgres Problem  (Najm Hashmi <najm@mondo-live.com>)
List pgsql-sql
Najm Hashmi writes:

> cmdb=# create table media_received (
> cmdb(# comp_id not null,
> cmdb(# dept_id not null,               ^
Those two fields should have a data type.  Same in your other examples.

> cmdb(# date_rec timestamp default 'now',
> cmdb(# units  int4  default 0,
> cmdb(# media_type varchar(64),
> cmdb(# enqued int4 check (enqued=<units),
> cmdb(# encoded int4 check(encoded=<enqued),
> cmdb(# insys int4 check(insys=<encoded),
> cmdb(# constraint media_rec_pk primary key(comp_id,dept_id,date_rec),
> cmdb(# constraint media_dept_fk foreign key(dept_id) references department,
> cmdb(# constraint media_comp_fk foreign key(comp_id) references company
> cmdb(# );
> ERROR:  parser: parse error at or near "not"

-- 
Peter Eisentraut      peter_e@gmx.net       http://yi.org/peter-e/



pgsql-sql by date:

Previous
From: "Josh Berkus"
Date:
Subject: Re: plpgsql grief
Next
From: Michael Fork
Date:
Subject: Re: Wierd postgres Problem