Displaying 1 result from an estimated 1 matches for "rests2feat".
Did you mean:
rests2feats
2006 Aug 22
0
Re: Problem with find condition and habtm relationship.
...urant has all of the asked-
for features if you can''t find one that it doesn''t have. It''s
incredibly annoying to try to think of things this way, but it''s what
SQL can do.
Let''s assume, to save some typing, your tables are called rests,
feats and rests2feats, and you''re looking for restaurants with a set
of features (''cheap'', ''kid-friendly''). The SQL you want should go
something like
select r.rest from rests r where not exists (select * from feats f
where f.feat in (''cheap'', '...