6 Replies Latest reply on Jun 26, 2013 6:58 AM by jbante

    Limit portal view with auto update




      i have a database with over 100,000 records and i need a portal view that only shows 10 add ones. In this portal i want not allow scrolling.


      On each record i want a button that i click when the work is done. In case the work is done, the data must disappear in the portal and the next must be add to the portal (so that at everytime i have 10 records in the portal).



      Does anybody know is a tool axist, that shows only records around my current position?

      In the portal i want only records that are near my current position. The records has currently only postal information( postcode, city and street).


      Many thanks


        • 1. Re: Limit portal view with auto update

          If I understand correctly the first is very simple. You set up a portal to show just 10 records without the bar so there is no scrolling you have a field in your table lets say completed you put a button in the portal when clicked to setfield (completed) =1 and you filter the portal with the "isempty(completed)"

          • 2. Re: Limit portal view with auto update



            If you want to show records that are only before or after the current record (say within five positions each way), it would be fairly simple to do.


            You would just filter your self joined portal on something like


            Records are only visible when:

            RelatedTable::PrimaryKey =< ( PrimaryKey + 5) and

            RelatedTable::PrimaryKey >= ( PrimaryKey - 5) and

            RelatedTable::PrimaryKey PrimaryKey


            However, adding a cartesian on a table with 100k records is a wonderful way to slow your database down to a point where it is irritating to use. I would suggest that you investigate and learn the virtual list technique to display only a small set of related "virtual" records based on your position. Loading 10 records vs. loading and filtering 100,000 records would make a huge difference.

            • 3. Re: Limit portal view with auto update

              OK, i have tried this on a mac and there it works.


              Do you have a idea for the second point?

              • 4. Re: Limit portal view with auto update

                The plan is, that we will have a connection to filemaker server. The permission will find out, how many records the differnet users have access to.


                I believe that thi s are perhabt 1000-5000 per user.


                This records muste be worked off and we dont want to give to mutch details to the users add once.


                In this case the user have 10 records, but maybe this records are to fare away. The best would be, that the ipad delivers the current possition , and the server will then linited the records to this location +50km f.e.


                But currently i have not found a solution for this.

                • 5. Re: Limit portal view with auto update

                  Armin, you have to find a geolocation example for filemaker to convert your address to GPS coordinates (on the server) you can find many examples to do that afterwards you need to put a button on the ipad verison to get your current location and do a search for a range in the server and then import the corresponding records. You have to decide the range of the coordinates

                  • 6. Re: Limit portal view with auto update

                    Once you have GPS coordinates for your records stored in your database, you can do a find constraining on latitude and longitude to within a certain (approximately) square region around the iPad's location, using the Location or LocationValues functions for the iPad's location, and a custom function like GeoBoxBounds to get the coordinate boundaries of the neighborhood around the location. Constraining to a square region is usually good enough for most applications; but if you really need a circular region, you can scan through the records in that resulting found set and omit the ones further away than your search radius (resulting in omitting the corners of the square region), using something like this GeoDistance function to determine the distance for each.