6 Replies Latest reply on Sep 20, 2012 10:52 AM by arnamy1

    related records in a portal not showing correct occurance

    arnamy1

      Title

      related records in a portal not showing correct occurance

      Post

           lets see if I can make this easy to understand....

           I have a database that was using a repeating field for tracking some dates. I exported it to switch over to using another table with separate records and showing a portal insted using these instructions....

           http://help.filemaker.com/app/answers/detail/a_id/7463/kw/list%20repeating%20fields

           So far so good. I need to run a report that searches for a date range, based on the date field that was the original repeating field. Now the serach works, but the report only shows the first occurance of what was that repeating fied. The reason I split this to a separate table with separate records was to show the correct record, but it is still only showing the first. 

           For example, if I search for 9/1/12 - 9/15/12, it will find all the records in that range, but if any of the records relate back to the record in the first table outside that range, it show the occurance of the other previous one.

           Does that make sense? Sure would love some input! Thanks in advance!

        • 1. Re: related records in a portal not showing correct occurance
          philmodjunk

               A portal means that you have a relationship. What is that relationship? (what fields match to what fields with what operator?)

               Is there a date in a date field in every portal record?

               Are you specifying this search criteria in a field from the layout's table or the portal's?

               This last detail makes a big difference in the results produced when you perform a find.

          • 2. Re: related records in a portal not showing correct occurance
            arnamy1

                 The relationship is that UniqueID those instructions worked me through. Table A has a UniqueID for all records. After exporting and splitting the repeating fields, table B has duplicates of that UniqueID. If I create a new record in Table B, from Table A, that UniqueID key stays the same in Table B.

                 I'm nut sure I'm clear on your second question, but there is a date field on the portal, but not every record in Table A has a relation to that portal that is Table B.

                 The serach criteria is specified in the portal's date.

                 Does that help? Thanks again!

            • 3. Re: related records in a portal not showing correct occurance
              philmodjunk

                   While in Browse mode, do you see all the correct data in the portal?

                   If you had 5 values in the repetitions of the original field, do you see all 5 values in your portal? (This is a check to see if you have the basic set up working for you or not.)

                   When you enter find mode and then specify find criteria in a portal's field, you are not finding records in the portal. You are finding records in the layout's table that have at least one related record that matches the criteria you entered into the portal record's field. Once you return to browse mode by performing the find, you once again will see all related records in the portal for the layout table's records that were thus pulled into the found set by performing this find.

              • 4. Re: related records in a portal not showing correct occurance
                arnamy1

                     I do have all the repeating values showing in the portal.

                     The find criteria I was doing through a script to create a report layout:

                     Enter Find Mode

                     Set Field to the date range I want to search in Table B (from the portal in Table A)

                     Perform Find

                     Go To Layout - the report that just just the date and another firld or 2

                     That report layout is where it will show the correct records, just not always the correct repetition.

                • 5. Re: related records in a portal not showing correct occurance
                  philmodjunk

                       In the layout that is current when you perform this script, which table is specified in Layout setup | Show Records From?

                       In the layout that the script changes to as its last step, which table is specified in Layout setup | Show Records From?

                       Unless you see the same exact name in Show Records From on both layouts, the find performed on the first layout has no effect on the records present on the second layout.Then keep in mind what I said about specifying search criteria in a field in a portal (or any field from a related table whether it is in a portal or not.). This finds records in your parent table--which then continue to match to the same set of records in the related table once the find has been performed.

                       I assume by "Correct Repetition" you mean that you don't see the data from the correct related record. If I have this figured out correctly, then you should be performing this find on a layout based on the Portal's table rather than your original "Parent" table. This layout can include fields from the related parent table to produce all the needed details for your report.

                  • 6. Re: related records in a portal not showing correct occurance
                    arnamy1

                         That did it! I needed the report to show records from Table B, not A.

                         Thank you so much! Glad I asked for help!