[postmodern-devel] fragile connection when creating new table?
Joe Corneli
jcorneli at planetmath.org
Wed Mar 7 23:12:45 UTC 2007
Hi,
I'm using postmodern under OpenMCL. Connected to an empty database,
I tried defining and creating a new table.
Doing this directly from the psql prompt gave a bunch of messages,
but doing it from within Lisp caused serious trouble. Compare:
1.
jcorneli=# create table strs (strid SERIAL PRIMARY KEY, string TEXT NOT NULL UNIQUE);
NOTICE: CREATE TABLE will create implicit sequence "strs_strid_seq" for serial column "strs.strid"
NOTICE: CREATE TABLE will create implicit sequence "strs_strid_seq" for serial column "strs.strid"
NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index "strs_pkey" for table "strs"
NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index "strs_pkey" for table "strs"
NOTICE: CREATE TABLE / UNIQUE will create implicit index "strs_string_key" for table "strs"
NOTICE: CREATE TABLE / UNIQUE will create implicit index "strs_string_key" for table "strs"
CREATE TABLE
2.
? (deftable strs ()
((str_id :type serial :primary-key t)
(string :type text :unique t))
(:indices str_id))
? (create-table 'strs)
; Warning: Postgres warning: CREATE TABLE will create implicit sequence "strs_str_id_seq" for serial column "strs.str_id"
; While executing: CL-POSTGRES::GET-WARNING
> Error in process listener(1): Postgresql protocol error: Unexpected message received: 1
> While executing: CL-POSTGRES::SEND-QUERY
> Type :POP to abort.
Type :? for other options.
1 > :POP
> Error in process listener(1): #<TCP-STREAM :CLOSED #x857FB3E> is closed
> While executing: CCL::STREAM-IOBLOCK
> Type :POP to abort.
Type :? for other options.
1 > :POP
This looks like a bug to me.
More information about the postmodern-devel
mailing list