4 Replies Latest reply on Mar 19, 2009 10:31 AM by raybaudi

    which value will show in 1-many relationship

    saurabh

      Title

      which value will show in 1-many relationship

      Post

      I have a table which records transaction between multiple contacts so there are following tables 

      1. Transactions

      2. Contacts with 2 table occurances Buyers and Sellers

      3. BuyerTransactionJoin

      4. SellerTransactionJoin

       

      Now in the transactions layout i want to show address of any one of the seller but as there are more than one sellers can i know in advance which address will be shown if i just show a related value <<Sellers::addressLine1>> i.e. is there any predictability in the way which related records are shown i.e. are they sorted by any specific value??

      I also want to show the list of all the sellers in a portal but i want to show the seller whose address is showing as the first value of the list in portal??? can it be done?? 

        • 1. Re: which value will show in 1-many relationship
          philmodjunk
             You will see the oldest related record. Note that what constitutes the oldest record can be changed if you sort the records and then import them into new copy of your file (when you're updating your solution or replacing a recovered/damaged file for example.)
          • 2. Re: which value will show in 1-many relationship
            saurabh
               sorry but i dont get it.. i am not importing so if the values exist in the system then what shall happen???
            • 3. Re: which value will show in 1-many relationship
              philmodjunk
                

              The first such related record to be created. Say I create 2 records with that match--one in the morning and one later on in the afternoon. The one created in the morning is the one I will see. You can check this by finding all the matching records and choosing "unsort". The first record in the set is the one that'll supply data to your layout via your relationship.

               

              What I wrote about importing is to caution you that which record is treated as the "oldest record" could be changed if you ever need to move your records via import into a different copy of your database. This is a fairly common procedure to do at some time during the life of your database, so be careful if you do.

               

              You might want to modify the design of your database so that you don't have to rely on this.

              • 4. Re: which value will show in 1-many relationship
                raybaudi
                  

                saurabh wrote:

                 

                ... i.e. are they sorted by any specific value??


                They aren't but you can sort the relationships by any value that you wish.

                 

                Go to the Relationship Grafh, double click the join symbol and, into the new window check the sort button on the side of Contacts.