9 Replies Latest reply on Nov 3, 2009 3:20 AM by Gert

    After sync of ODBC/MySQL file, relation uses wrong fields

    Gert

      Summary

      After sync of ODBC/MySQL file, relation uses wrong fields

      Description of the issue

      Adding new fields (or renaming) in the MySQL file distorts the order of existing fields in a TO and the set of fields used for a relation.After that the relation points to the wrong fields in the table.

        • 1. Re: After sync of ODBC/MySQL file, relation uses wrong fields
          TSGal

          Gert:

           

          Thank you for your post.

           

          The original table occurrence was based upon the old field values.  With my tests, the field names do not update in the original table occurrence.  However, when I bring in a new table occurrence, all the fields are present (the new fields and the edited field names).  I can then reset the relationships to the new table occurrence and everything displays properly.

           

          I could not get a distorted order of existing fields in the original table occurrence, nor di any of the relations point to the wrong fields in the table.

           

          TSGal

          FileMaker, Inc. 

          • 2. Re: After sync of ODBC/MySQL file, relation uses wrong fields
            Gert
              

            Ah, but that differs from the way I sync-ed.

             

            In the field-editing view, to the right of the current table name, is a button named 'Sync'.

            Pressing the button retrieves new info from the MySQL table.

            • 3. Re: After sync of ODBC/MySQL file, relation uses wrong fields
              TSGal

              Gert:

               

              "Sync" button?  I am unable to find this button, and I have worked with a couple of other Technical Support agents, and we still cannot find a "Sync" button.  Can you be a little more descriptive?  That is, what steps do I take to get access to the "Sync" button?

               

              TSGal

              FileMaker, Inc. 

              • 4. Re: After sync of ODBC/MySQL file, relation uses wrong fields
                Gert
                  

                Field-editing is too vague a description. How about database-management view?

                It's where the properties of the fields are edited.

                • 5. Re: After sync of ODBC/MySQL file, relation uses wrong fields
                  TSGal

                  Gert:

                   

                  "Field=editing" is the term you originally used.  In any case, this still doesn't matter.  When I go to "Manage -> Database...", I can click the Fields tab to see the field information, and I can click the Relationship tab to see the overall database and table views.  None of the options for the field (in Fields view) has a Sync button.  Please provide exact steps you take in FileMaker.  This would be more helpful.

                   

                  TSGal

                  FileMaker, Inc. 

                  • 6. Re: After sync of ODBC/MySQL file, relation uses wrong fields
                    Gert
                      

                    Hello tsgal,

                     

                    I used the term, and realised later that there is so much field-editing going on in FM that it was not the best way to describe the place.

                     

                     

                    Below a nice snapshot of the mysterious 'Sync Button'...

                     

                     

                     

                     

                    • 7. Re: After sync of ODBC/MySQL file, relation uses wrong fields
                      mrvodka
                        

                      If you resync the ESS table, and fields have been renamed, you will have to go and change where they have been referenced as FileMaker seems to explicitly refer to to these external fields. IOW, FileMaker can not realize that they have changed.

                       

                      It is like if you have a SQL statement of:

                       

                      SELECT fname, lname

                      FROM Table

                       

                      If you change fname to firstname, the SQL statement doesnt automatically change. So it is still looking for fname.

                      • 8. Re: After sync of ODBC/MySQL file, relation uses wrong fields
                        TSGal

                        Gert:

                         

                        Thank you.  I was looking at the destination; not the origination.

                         

                        Yes, when you sync with the SQL (origination) table, any new fields added or edited will appear below the previous set of fields.  My relationships were not affected except for those field names that were edited, because those fields are now non-existent.  I was able to select those fields and assign them to the new field names.

                         

                        TSGal

                        FileMaker, Inc. 

                        • 9. Re: After sync of ODBC/MySQL file, relation uses wrong fields
                          Gert
                            

                          When cleaning up shadow fields, sometimes a key-slot in the relation changes to 'unknown', sometimes it randomly picks another existing key. This second case is dangerous; FM is not in an invalid state yet it the solution is not longer as it was designed. (With slot I mean a place in the list of keys for a relation)

                           

                          I was not warned that slots were reassigned, I saw it by accident. When  relation graphs are complicated, the visual search for all changes might not find all of them. This may not be a bug in the software, but this behaviour was against my expectations based on FM's usual behaviour that it will do its utmost best to protect me from the mess that can be a consequence of my stupid actions. (Although it not always succeeds. I can define 2 computation fields that reference each other, after that they can't be removed)