6 Replies Latest reply on Mar 5, 2009 7:58 AM by TSGal

    how to delete certain data from a specified date range

    rayce

      Title

      how to delete certain data from a specified date range

      Post

       

       

      I have a layout where there are repeating fields that are being used to specify transactions from different dates.

       

      My task is how to generate and show only those that are needed from a certain date range.

       

      For example, today is already february 2009 and i need to show only those transactions made from 2008.

       

      How can it be done?

       

       

      Thank you, all answers will be much appreciated.

        • 1. Re: how to delete certain data from a specified date range
          ninja
            

          howdy rayce,

           

          Thanks for the post.

           

          I hope that this answer is appreciated...it might actually cause a bit of work.

           

          Consider whether repeating fields are the best way to go about storing dated information.  Would a "transaction Table", portaled in, be more appropriate?  With a transaction table, your date search would be pretty simple, a find in a transaction date field in the transaction table...

           

          Unfortunately I don't have an answer for you in searching your repeating fields, but this post will at least move the thread to the top of the list again so someone else can take a stab at it.

           

          Enjoy the day!

          • 2. Re: how to delete certain data from a specified date range
            TSGal

            rayce:

             

            Thank you for your post.

             

            Think of a repeating field as one field with many values.  For example, a text field can contain many words.  If you search for "test" in a text field, it will show all records where "test" displays.  It will NOT remove the other words around it.  This is the same for the repeating field.  If you search for "test" as one of the values in the repeating field, it will find those records where "test" appears as one of the repeating values.

             

            Pull down the File menu and select "Save a Copy As..."  Select the option "clone (no records)".  This makes an exact copy of the database file with no records.  Open the clone file and import from your main file.  One of the options that appear during import is to split the repeating values into separate records.  This way, "test" will be put into its own record.  At this point, you can now search for those transactions from 2008 and run a report.

             

            Let me know if you need clarification for any of the above steps.

             

            TSGal

            FileMaker, Inc. 

            • 3. Re: how to delete certain data from a specified date range
              rayce
                

              Thank you for all your replies

               

              I will give you an example

               

              date1             number1         detail1         date2        number2         detail2

              01/01/07        111                abc             02/02/09    444                jkl

              01/01/08        222                def             02/02/07     555               mno

              01/01/09        333                ghi              02/02/08    666                pqr

               

               

              when you split this example into separate records, the 3 rows will be separated to 3 different files.

               

              date1           number1            detail1             date2          number2          detail2

              01/01/07      111                   abc                 02/02/09      444                 jkl

               

              date1            number1            detail1            date2           number2         detail2

              01/01/08           222                def               02/02/07         555               mno

               

              date1            number1            detail1              date2          number2          detail2

              01/01/09        333                    ghi               02/02/08         666                pqr

               

               

               

              my question is, if i only need those transactions  that are made from the year of 2008, how can i delete those that are from 2007 and 2009 using a command or whatever process is necessary?

               

               

              Thank you! 

              • 4. Re: how to delete certain data from a specified date range
                TSGal

                rayce:

                 

                When you split the repeating fields into separate records, you can then perform a Find in the "date1" field for 2008.  That will give you the desired found set.

                 

                TSGal

                FileMaker, Inc. 

                • 5. Re: how to delete certain data from a specified date range
                  rayce
                    

                  thank you for your reply

                   

                  i already know how to search, my question is how to delete those that are not from a specified year, without removing other data that are with the same row when they are separated. 

                  • 6. Re: how to delete certain data from a specified date range
                    TSGal

                    rayce:

                     

                    There are two ways to delete records from a specified year.

                     

                    1 - Find for 2008 (the year you want).  Then, pull down the Records menu and select "Show Omitted Only".

                     

                    2 - Enter Find Mode, enter 2008 into the date field, and click the Omit button.  When you press return, it will omit all records that occur in 2008.  Essentially giving you the same search as step #1.

                     

                    ------------

                     

                    You can now pull down the Records menu and select "Delete Found Records...".  This will permanently remove those records from the table.

                     

                    TSGal

                    FileMaker, Inc.