14 Replies Latest reply on Nov 12, 2013 12:11 AM by gdurniak

    Layout keeps losing it's link to table

    donnyl

      Got a strange one here on v.12. Have a simple form view layout that keeps losing it's link to its table which in turn, every field displays the "<Unrelated Table>" message (see attachment). I can reset the table to the layout ok but as soon as I switch to another layout and then come back to this form layout, it will have lost its connection to the table again.

       

      Things I've tried:

       

      1. Recover - had no effect

      2. Restored file from backup (last known "pre-issue" one) - this worked fine at first but after using the database for about an hour, the error happened again..

      3. Created a new form layout from scratch (not duplicating) - this worked fine at first but once the layout was populated with all the pertinent fields, the error started up again.

       

      Platform - Mac OS 10.7.5, FMS 12.0.4, FMPA 12.0v5

        • 1. Re: Layout keeps losing it's link to table
          wsvp

          Is the layout based on a Table Occurance that accesses another Table through a relationship?

          • 2. Re: Layout keeps losing it's link to table
            LyndsayHowarth

            You don't have a bug so no amount of recovery will help.

             

            What you have done is (probably) chosen the wrong table occurance for that layout.

             

            I think you need to go back to basics and read some of the excellent articles on relationships in the Technical Resource Centre (see tab above).

             

            A layout displays records from a table (or table occurrence).

             

            If one customer has 5 invoices, you would have one layout for customers and one layout for invoices and draw a relationship between them where the customer ID in customers table matches the value in the customer ID field in 5 Invoices. From Customers you can show a portal of the Invoices... and from Invoices you can show the address details for the related customer.

             

            Table occurances can also be created for other purposes. You may have a due date in invoices and a current date in Customers and a relationship to the invoices called Overdue Invoices where the match is by the customer ID and the current Date > Due Date.

             

            You may also have a table of products. If you had a layout for products but showed the fields from Customers... you would get the "<Unrelated Table>" message. The two tables simply do not relate to each other.

             

            HTH

             

            - Lyndsay

            • 3. Re: Layout keeps losing it's link to table
              pminich

              I don't think that explains why it works initially though. The records are

              either related or not.

               

              --

              iPhone

              Pete Minich

               

               

              Direct/FaceTime/Text  - 781.223.8884

              • 4. Re: Layout keeps losing it's link to table
                DamianKelly

                Can you send a screenshot of it working including the status area?

                • 5. Re: Layout keeps losing it's link to table
                  LyndsayHowarth

                  ... and you change nothing in the layout or schema of the database in between it working and not...?

                   

                  I rather suspect that it works when they are related and doesn't when they are not. It is possible your relationships are a bit tangled. Perhaps you should post a copy of the database to let us see what the issue might be. It will save a lot of typing...

                   

                  - Lyndsay

                  • 6. Re: Layout keeps losing it's link to table
                    donnyl

                    I added a couple of screen caps that should help. I did double check the table and it appears to be the right table. FYI, I wasn't the one who set up the tables/relationships/layouts.

                    • 7. Re: Layout keeps losing it's link to table
                      DamianKelly

                      And I assume the layout is based on the PRJ table occurance?

                      • 8. Re: Layout keeps losing it's link to table
                        Stephen Huston

                        A couple of other thoughts:

                        1. Check to see if the relationship's key fields are fully indexed on both sides of the relationships used for this layout.
                        2. Calculated keys sometimes work only one direction, so viewing from the wrong table (TO) can provide unexpected or inconsistent results.
                        1 of 1 people found this helpful
                        • 10. Re: Layout keeps losing it's link to table
                          Tom_Droz

                          Donny

                           

                          Layouts and objects on them can also become corrupted.  I would suggest you try creating a new layout and place recreat some of the fields and see if the condition continues

                          Tom

                          1 of 1 people found this helpful
                          • 11. Re: Layout keeps losing it's link to table
                            donnyl

                            Thanks Tom. You confirmed what I suspected all along. Not only did I create a new layout, but an entire new file. I tried doing just the new layout (not duplicating) but it ended up doing the same error. So, the only thing really left to do was create a new file. It now appears to be working fine. I have been working with FMP since 1990 and this was the first time I have ever had a file get corrupted. Pretty good track record for Filemaker if you ask me.

                             

                            Thanks to all who responded. FMP developers are the best!

                            • 12. Re: Layout keeps losing it's link to table
                              LyndsayHowarth

                              Sorry.. I pitched my response toward the novice end.... sometimes it is hard to tell. My assumption was that if you had been around a long time you would have come across corruption before and know what Tom suggested. (To ASSUME is to make an ASS out of U and ME ;-)

                              Corruption of (objects on a) layout used to be a rare thing. It seems to a lot more common these days. I understand that for converted files but new files should not have issues this regularly.

                               

                              - Lyndsay

                              • 13. Re: Layout keeps losing it's link to table
                                donnyl

                                Lyndsay, np. Like I said, in all my years of developing fmp solutions, this is the first I've personally encountered a corrupted object/layout. That's why I posed the issue here.

                                • 14. Re: Layout keeps losing it's link to table
                                  gdurniak

                                  If you had the same problem with a new layout, then the internal catalog of that Table Occurance or a Key Field may be scrambled

                                   

                                  And a question mark for Project ID is odd too. Try importing all data into a clone. You could have a "phantom" record

                                   

                                  Please consider calling Tech Support, and sending them your file. Perhaps FM 12 Recover needs an update, to see this

                                   

                                  greg

                                   

                                  PS

                                  Just by chance, does it work when you open the Recovered File ?

                                   

                                   

                                  >  I tried doing just the new layout (not duplicating) but it ended up doing the same error. So, the only thing really left to do was create a new file.