Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

In a many-to-many relationship, how to find records that relate to two specific items?


This topic is 1740 days old. Please don't post here. Open a new topic instead.

Recommended Posts

  • Newbies
Posted

I would appreciate some help if anyone knows how to solve this. 

I have a database with three tables. The first is a Recipe table, with fields RecipeID, RecipeName, etc. The second is an Ingredient table, with fields of IngredientD, IngredientName, etc. The third is a RecipeIngredient table that joins the above tables together, with fields of RecipeIngredientID, RecipeID that links to the Recipe table, IngredientID that links to the Ingredient table, Amount, etc.  The three tables form a typical many-to-many relationship.

I have been trying to figure out how to find a recipe that contains two specific ingredients.  For example, I tried the Criteria “RecipeIngredient::Ingredient: [Carrot] AND RecipeIngredient::Ingredient[2]: [Potato], but it didn’t work. Any suggestions? Thanks in advance!

This topic is 1740 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.