3 Replies Latest reply on Jan 20, 2009 10:15 AM by stellagirl12

    Sorting by a Series



      Sorting by a Series


      Hello. Is there a way in FileMaker that I able to sort by a series of dates? I have a database I am currently using to manage my contacts. I would like to be able to pull up the contacts that have been recently contacted, say in the past 2 months; I would like to be able to sort this database through a series of dates:

      Ex. 1/30/07 - 3/30/07

      and then the database would pull up just those contacts that have been contacted within those dates (each contact entry has its own "date of contact" field assigned to it). My database is in FileMaker and I am using BBEdit to manage the web based portion. Any help or information would be greatly appreciated.


        • 1. Re: Sorting by a Series

          Howdy stellagirl12,

          thanks for the post.


          I think you are looking for a "find" rather than a sort.


          - Enter find mode

          - click in the field you want to search

          - enter {first date} ... {last date}

          - hit 'Enter'

           The key here is the three dots, this will result in all records within the range (do not use spaces)


          If you additionally want to sort the found set, you can do that under the "records" drop down menu or automate the whole thing with a script.


          Is this what you were after?

          • 2. Re: Sorting by a Series

            Hi stellagirl12


            Welcome to the forum, is this search just for FileMaker or do you want this on the web also.


            For the FileMaker part you just want to create a script that performs a find based on a date range and then sorts that found set for you, your script would look something like this:



              Enter Find Mode [] // Remove the option to Pause

              Set Field [ date of contact ; 

            Date ( Month ( Get ( CurrentDate ) ) - 2 ; Day ( Get ( CurrentDate ) ) ; Year ( Get ( CurrentDate ) ) ) 
            & "..." &
            Get ( CurrentDate ) ]

              Perform Find [  ] 

              Sort Records [ Specified Sort Order: date of contact ; No dialog ] 

              Go to Record/Request/Page [ First ] 


            The Calculation in the Set Field step created a date range search gong back two months from the current date, same date two month ago i.e. 20/11/2008...20/01/2009, you can amend this part to your own date range. 

            Then attach this script to a button on your layout and it will find all records that have a call date in the previous two months and sort them by the date.


            Let me know if this does the trick for you. 

            • 3. Re: Sorting by a Series
              Thank you for your respones.  In response to Orlando's question: Yes, I would like to be able to sort/find this data while using the web rather than in the actual FileMaker program.  Is it something that needs to be done in FileMaker before it can be implemented on the web?
              Thanks, again.