Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> select a group from a group
Hi,
I need your help in solving this problem:
we have the following tables:
property(propertyID(number), propertyName(number))
articleProperty(articleID(number), propertyID(number))
locationProperty(locationID(number), propertyID(number))
as U may guess in last tables propertyID refences propertyID in first
table.
having one articleID, find all locations that have at least the same properties as that article. (at least means locations _must_ have articles's prop but can have other props also)
my best guess is:
select distinct l.locationid from locationproperty l where
(select propertyid from articleproperty where articleid=1) in
(select propertyid from locationproperty where
locationid=l.locationid)
of course this dose not work.
thanks Received on Mon Sep 24 2001 - 09:07:56 CDT
![]() |
![]() |