That was a hard task!
I got Torque 3.0 going with Postgres sequence-support. It just took me 2 days 
including a lengthy debug-session in Eclipse.

1) The Schema

a) <database defaultIdMethod="autoincrement">
native might also work but the db-adapter registers autoincrement

b) if Torque generated the schema, delete all default entries from sequences, 
otherwise the classes won't compile (something like "default= 
&quot;nextval('table_id_seq'::text)&quot;")

c) For each table that uses sequences add an entry
<id-method-parameter value="table_field_seq"/>

2) Torque.properties

The default entry looks like this

torque.database.default=bookstore
torque.database.callaproject.adapter=postgresql

Unfortunately Torque tries to look up the db-adapter from a "default" entry 
and therefore doesn't find DBPostgres but DBNone (yet another bug...)
No problem: add
torque.database.default.adapter=postgresql

-- 
Dipl. Inf. Carsten Burghardt
Login & Solutions AG
email: [EMAIL PROTECTED]
Tel: 0821/2488-311     Fax: 0821/2488-180


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to