Define a Foreign Key with a One-to-One mapping
Neil Sherman <[email protected]> Tue, 31 May 2011 12:31:49 +0100
| Newsgroups | gmane.comp.jakarta.turbine.torque.user |
|---|---|
| Message-ID | <OF0F4C46EF.B3C480D7-ON802578A1.003F0175-802578A1.003F567F@trapezegroup.com> |
Hi,
This may be a bit of a simple question but...
How do I define a foreign key in my Torque schema with a one-to-one
mapping ? No matter what I do I always seem to end up with a one-to-many
relationship ?
I've tried adding in multiplicity option but it doesnt seem to have any
effect:
<foreign-key foreignTable="styledJourneys">
<option key="bidirectional" value="false"/>
<option key="multiplicity" value="one-to-one"/>
<reference local="journeySetID" foreign=
"journeySetID"/>
</foreign-key>
I'm using mySQL 5.1 as my database backend
Thanks for your time
Neil