My understanding is when you reference another table you are referencing
the hidden column autoid, which indexes its unique columns. So a
reference to another table is always to its unique columns. Unique
columns are only needed in the table being referenced to, which my
example has (upper table references the unique 0 100 1 and 0 200 1 from
middletable, which in turn reference the unique 0 100 and 0 200 from
lowertable). The problem, as Devon found, is that JDB doesn't seem to
handle references to unique data which is unique only by reference to
another table (that is, if we instead had 0 100 0 and 0 200 1 in
middletable we'd be fine, since the uniqueness is in middletable without
its reference to lowertable).

Jordan

-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of Raul Miller
Sent: Wednesday, September 23, 2009 11:59 AM
To: Programming forum
Subject: Re: [Jprogramming] JDB wrong data

On Tue, Sep 22, 2009 at 11:52 PM, Devon McCormick <[email protected]>
wrote:
> Not sure I really understand this, but if "midkey" has unique values,

JDB's documentation says it expects unique columns
for references to other tables.

-- 
Raul
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to