December 10, 201015 yr Newbies Forgive these basic questions (not basic to me)as I am struggling to understand a simple relationship. Cooking is my main hobby and I have a notebook of different recipes and lists of ingredients for each recipe. So as I am now retired with time on my hands I thought I would try a file to hold this information. I just know the basics of Filemaker and have created 2 tables one containg the recipes the other the ingredients. I want each recipe record to relate to its corresponding ingredient record. So my first question is: Would this be a one to one relationship as each recipe only relates to one set of ingredients? I am a little confused on this foreign and primary key bit. In each table I have a serialID which has the Serial number checked in Auto-Enter would this field act as the key beween each table in the relationship, and have to be linked in the relationship graph? Finally how do I view the two tables on the screen at the same time? I am using Filemaker 11 Many thanks for any information on this. jack
December 10, 201015 yr Actualy, what you have is a many to many relationship from Recipe to Ingredients. You will need a third table called a join table (if you do a search for join table you will find many posts on the subject). The join table in this case would represent a set of ingredients. one recipe can have many ingredients and 1 ingredient can be used in many recipes.
December 10, 201015 yr Would this be a one to one relationship as each recipe only relates to one set of ingredients? A set of ingredients has many ingredients - so this would be one recipe to many ingredients. The rest depends on how you want to enter the ingredients: if you re-enter the same ingredient for each recipe, you'll have a one-to-many relationship. If you want to select a common ingredient from a Products table, you will have a many-to-many relationship between Recipes and Products, with Ingredients being a join table in-between: Recipes - < Ingredients >- Products how do I view the two tables on the screen at the same time? By placing a portal to Ingredients on a layout of Recipes.
Create an account or sign in to comment