Thanks Luca,
That's just what I needed, fantastic! phew.
Cheers.
Edwin Yearwood
Developer
BTG
Reuters
Telephone +44 (0)207 542 5818
Email edwin.yearwood@reuters.com
Reuters Messaging edwin.yearwood.reuters.com@reuters.net
-----Original Message-----
From: Luca Zappa [mailto:luca@lucazappa.com]
Sent: 01 March 2004 16:19
To: torque-user@db.apache.org
Subject: Re: Id method native "How to"?
You can specify the sequence name with id-method-parameter tag inside the table defination:
<id-method-parameter value="YOUR_SEQUENCE_NAME"/>
Example:
<table name="book" description="Book Table">
<column
name="book_id"
required="true"
primaryKey="true"
type="INTEGER"
autoIncrement="true"
description="Book Id"/>
<column
name="title"
required="true"
type="VARCHAR"
size="255"
description="Book Title"/>
<column
name="isbn"
required="true"
type="VARCHAR"
size="24"
javaName="ISBN"
description="ISBN Number"/>
<column
name="publisher_id"
required="true"
type="INTEGER"
description="Foreign Key Publisher"/>
<column
name="author_id"
required="true"
type="INTEGER"
description="Foreign Key Author"/>
<id-method-parameter value="YOUR_SEQUENCE_NAME"/>
<foreign-key foreignTable="publisher">
<reference
local="publisher_id"
foreign="publisher_id"/>
</foreign-key>
<foreign-key foreignTable="author">
<reference
local="author_id"
foreign="author_id"/>
</foreign-key>
</table>
-----Original Message-----
From: Edwin Yearwood <Edwin.Yearwood@reuters.com>
Sent: Monday, 1. Mar 2004 16:37 +0100
To: torque-user@db.apache.org
Subject: Id method native "How to"?
Please, does anyone know how to setup the schema.xml for Oracle native (auto increment) support.
How to define a table as a using a specified sequence ...etc?
Thanks.
Edwin Yearwood
Developer
BTG
Reuters
Telephone +44 (0)207 542 5818
Email edwin.yearwood@reuters.com
Reuters Messaging edwin.yearwood.reuters.com@reuters.net
--------------------------------------------------------------- - Visit our Internet site
at http://www.reuters.com
Get closer to the financial markets with Reuters Messaging - for more information and to register,
visit http://www.reuters.com/messaging
Any views expressed in this message are those of the individual sender, except where the sender
specifically states them to be the views of Reuters Ltd.
---------------------------------------------------------------------
To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
For additional commands, e-mail: torque-user-help@db.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
For additional commands, e-mail: torque-user-help@db.apache.org
--------------------------------------------------------------- -
Visit our Internet site at http://www.reuters.com
Get closer to the financial markets with Reuters Messaging - for more
information and to register, visit http://www.reuters.com/messaging
Any views expressed in this message are those of the individual
sender, except where the sender specifically states them to be
the views of Reuters Ltd.
---------------------------------------------------------------------
To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
For additional commands, e-mail: torque-user-help@db.apache.org
|