Re: ForeignKey-Constraint with more than 1 tables
Date: Fri, 28 Mar 2008 10:43:00 +0100
Hans Mayr schrieb am 28.03.2008 in
> Hi Andreas,
> Maybe it is a solution to create a unique ID for each location. A new
> table TTreeLocations with LocationID, LocationType (Street,
> Park, ...), ObjectID (this being the ID of street, park etc.) would be
> a way to do this.
Soory, but I can not find the difference. If I understand correct you suggest to create a table TTreeLocations with a primary key LocationID and an ObjectID that now has to refer different tables, street, park ...
It is no problem to use 1 sequence for all referred tables street, park and so on, but how can I write a constraint, that ensures, that my ObjectID is to be found in (exactly) one of these tables?
-- wenn email, dann AndreasMosmann <bei> web <punkt> deReceived on Fri Mar 28 2008 - 04:43:00 CDT