5 Replies Latest reply on Nov 10, 2016 1:06 PM by erolst

    Very slow portals

    sam.gordon

      I am trying to create a day sheet calendar for my business.  I run a dance studio.  I have between 10-13 teachers working here at different times.  The day sheet should be a grid of squares 13 across and 13 down on a legal sized document.  It should display each teachers name at the top of the columns respectively and each row would designate an hour from 9 am to 9 pm.  Each square would then represent any appointment for the teacher in that column for the corresponding time.  The way I came up with to do this was to have a table of appointments.  Each record in that table would contain the date, time, teachers name and students name.  I created a table for the actual day sheet that only contains a date field and created the relationship between the two to be the date.  Next I created a portal for each square of the grid based on the date relationship to the appointments table.  Then I filtered each portal based on the date, the teacher for that column and the time for that row.  Each portal would be filter down to just one recored.  When testing it out I only created the portals for 1 column to make sure all the filtering would work as planned and it did.  Here is the problem.  After adding the rest of the columns, it now runs terrible slow.  When I try to change the date on the day sheet table it can take as much as 3-5 seconds for it to accept the new date and then load the portals.  I often get the spinning rainbow wheel.  I realize that I have 169 portals on page.  Is that just too much for file maker to handle?  Even if the appointments table only has 10 appointments it still goes very slow.  Is there anyway to optimize for faster loading?  For the recored I am using Filemaker Pro 15 Adv.  I have not noticed portal threading taking  effect either. 

       

      If this is just too many portals to deal with at one time can anyone suggest and different method to help me accomplish a day sheet task?  It should be noted that I have been using Filemaker for many many years but I am self taught and not a trained programer or developer.   Thanks.

       

      Sam

        • 1. Re: Very slow portals
          philmodjunk

          More than the number of portals, it's also due to the fact that everyone of them is filtered.

           

          Try using a single portal for a complete column--make a record for every hour for that teacher even if it's open. Add some more fields to your layout table so that you can match records by date and teacher to eliminate the need for a filter.

          • 2. Re: Very slow portals
            philipHPG

            169 filtered portals on one layout is quite a bit, especially as portal filtering is done locally - so the appointment data is downloaded to the client (for each portal, I believe) and then it is filtered. The more filtering you can do at the relationship-level the better - it sounds like you have done some of that with the date (although you later mention that the *portal* is also filtered by date). I'm not sure what your structure is and whether it is possible to do additional filtering at the relationship-level, although that would multiply the number of table occurrences.

             

            One alternative would be to base the layout on a table of global fields that are calculated when the date is changed. That takes a little bit of scripting work, but could well improve performance.

            • 3. Re: Very slow portals
              Stephen Huston

              If your Relationship Key is the date field, you don't need to filter by date as well. The suggestion to prepopulate the date/time records is a good one for removing the time filters and making each teachers' portal a single portal of all times.

               

              And, 3–5 seconds for a full screen date-refresh doesn't sound bad, but should improve with the suggested changes.

              • 4. Re: Very slow portals
                sam.gordon

                Thanks.  Reducing the filtering has helped a lot.  I am so going to try the global fields idea later and see how that works.  I like complex scripting. 

                • 5. Re: Very slow portals
                  erolst

                  sam.gordon wrote:

                  I like complex scripting.

                   

                  Haven't heard that one before