db-torque-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Thomas Fischer <fisc...@seitenbau.net>
Subject RE: Fwd: Columnmap only support one foreingkey
Date Wed, 20 Feb 2008 08:34:01 GMT
"Greg Monroe" <Greg.Monroe@DukeCE.com> schrieb am 19.02.2008 23:07:13:

> Thomas Fischer said:
>
> > On Tue, 19 Feb 2008, Fran Ferri wrote:
> > >
> > > Why the columnmap only supports one related column?
> > > Is an update pending?
> >
> > It seems that this particular information in ColumnMap does not
> > support multiple foreign key relations per column.
> > ...
> >
>
> I'm not even sure why this is needed?  AFAIK, the SQL standards
> specifies:
>
> The foreign key identifies a column or a set of columns in one
> (referencing)
> table that refers to a column or set of columns in another (referenced)
> table.
> The columns in the referencing table must be the primary key or other
> candidate key in the referenced table. The values in one row of the
> referencing columns must occur in a single row in the referenced table.
>
> I'd interpret this as each column can only have one matching column in a
> single remote table.  If you want the "ordering" for the remote tables'
> primary key set, you can get that by looking at the remote table's
> information.
>
> But I could be wrong about in this.  I'd be curious to see the SQL that
> would define the multiple foreign key on one column.  And then to see
> how many of the common Database servers support it.

I'm quite sure one can have multiple Foreign keys per column. Look at the
"C" table in the test project. (not exactly what you wanted, but one column
occurs is a single FK and is part of a composite FK as well)

    Thomas


---------------------------------------------------------------------
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