db-torque-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From T E Schmitz <mail...@numerixtechnology.de>
Subject PostgreSQL SEQUENCE problem
Date Wed, 24 Mar 2004 23:31:28 GMT
Hello,

The SQL generated for PostgreSQL using defaultIdMethod "native" causes a 
problem with PostGreSQL 7.2.1 (Debian Linux):

For each autoIncrement primary key a CREATE SEQUENCE statement is 
generated followed by the CREATE TABLE statement. The latter fails 
because this version of PostgreSQL automatically creates a SEQUENCE for 
each serial column. The table is not created if the SEQUENCE already 
exists.

I removed line 7 "#if ($sequence.length()>0)$sequence#end" from 
sql\base\postgresql\table.vm

The resulting SQL now works fine.

As an aside, this version of PostgreSQL does not automatically drop the 
SEQUENCE when dropping the table.

-- 


Regards,

Tarlika Elisabeth Schmitz

---------------------------------------------------------------------
To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
For additional commands, e-mail: torque-user-help@db.apache.org


Mime
View raw message