2 Replies Latest reply on Mar 25, 2013 9:55 AM by productionQC

    Help with relationships...



      Help with relationships...


           Hi.  I am not brand new to this, but I am having trouble wrapping my brain around a problem I have extracting data through relationships.  Below is a jpeg of my setup.  My problem is with the far right table, "Service Request".  On this table, and the layout associated with this table. the user must select a builder and subtrade from drop down lists.  Once they select a subtrade, that subtrades details populate each field, like phone, contact, address etc.  The drop down list is a local field called "Issue To"  from "Service Request table" and is populated using the "Use values from field" option in the value list.  The values are grabbed from SUBTRADES::SUBTRADE_ID.  This setup works perfectly, as it should.  But my question is this...I can't for the life of me make the same setup for builders work.  The client can see all of the builders int the dropdown list, but once selected the the information fields (phone, addresss, contact etc) do not populate as they do for subtrades.  If I try to link Service Request with builders it tell me I can't because "There cannot be more than one realtionship between any two tables in a graph..."  Furthermore, if I break the link to subtrades and move it to builders, the builder dropdown list works perfectly and popluates the builders info after the user selects it.  I can't make both work at the same time!!!  HELP



        • 1. Re: Help with relationships...

               What you show in your screen shot aren't really tables--though FileMaker calls them that. They are what we call "table occurrences". Whil you can't link to Builders or Builders 2, you can link to a new Tutorial: What are Table Occurrences? that refers to the same data source table as it does.

               You can:

               Enter Manage | Database | relationships, make a new table occurrence of Builders by clicking it and then clicking the duplicate button (2 green plus signs). You can double click the new occurrence box to get a dialog to appear where you can rename the new occurrence box to be SelectedBuilders if you want.

               We have not duplicated a table. Instead, this is a new reference to the same table already present in your database.

               Add it to your relationships like this:

               Service Request::_fkBuilder_id = SelectedBuilder::Builder_id

               Then add fields from SelectedBuilders to your Service Request layout to show the name, address, etc of that builder or set up fields in Service Request that use looked up value field options to copy this same data from SelectedBuilder.

          • 2. Re: Help with relationships...

                 Phil, that did it!!!

                 Thanks again...I should have thought of that, but as you stated, I have to treat them as tables rather than occurances.  

                 Thanks for clearing that up!!!