3 Replies Latest reply on Jun 4, 2010 2:18 AM by comment_1

    Filtering Records through Relationship

    Uli

      Title

      Filtering Records through Relationship

      Post

      Since I'm a newbie to FMP11 I created a artist table with contact information and a status field that stores their status (accepted, in progress, denied). i created a TO  and would like to display only the records of artists that are accepted in a view. I don't seem to get my head around it how to do it without using portals. Any help would be greatly appreciated.

       

      Uli

        • 1. Re: Filtering Records through Relationship
          comment_1

          If you don't want to use a portal, you can simply find the records where status = "accepted". No relationship is required for this.

          • 2. Re: Filtering Records through Relationship
            Uli

            Hi comment,

            thanks for your reply. I put a script that includes a find function on "onLayoutEnter" as you describes which works fine. The only thing is my Get(RecordCount) and Get(FoundRecord) are getting messed up and the GoToRelatedRecord which points to this artist table from a second  table (media asset table) doesn't work anymore.

             

            I think the "elegant" way would be to do the filtering in the DB and not through scripting. What do you think?

             

            Thank you.

             

            Uli

            • 3. Re: Filtering Records through Relationship
              comment_1

               


              Uli wrote:

              The only thing is my Get(RecordCount) and Get(FoundRecord) are getting messed up


               

              Not sure what you mean by that.

               

               


              Uli wrote:

              the GoToRelatedRecord which points to this artist table from a second  table (media asset table) doesn't work anymore.


               

              I believe it does work - but the script trigger works as well. You ned to find a way to make the script work only under certain conditions - or use a different layout.

               

              Note that GTRR and Find are just two different ways to create a found set.