3 Replies Latest reply on May 11, 2015 3:39 PM by philmodjunk

    ID Change With Auto Entry



      ID Change With Auto Entry


      I have an issue with auto entry being lost when I change the ID field in one of the tables.  I have 2 tables and both are related through an ID field.  The second table has some auto entry fields by calculation that pull information from the first table.  If I change the ID for one of the records in the first table, I loose the auto entry fields for that record in the second table.  The fields return if I manual change the ID in the second table to match the first.

      Is there a way to establish auto entry for the ID field in the second table?  When I try to do this by calculation, the database file locks up.

        • 1. Re: ID Change With Auto Entry

          It doesn't sound like your are losing any auto-entered data. Rather it would appear that you are losing the entire record--as would be expected when you change the value of an ID field that links the two records in a relationship.

          • 2. Re: ID Change With Auto Entry

            Your right.  I have been playing around with this for some time and I'm not resolving the issue.  I have 2 tables: a CUSTOMER table and a PRINT table.  The PRINT table is filled with various auto entry fields only - never a need to open this table and add or change anything.  When I create a record in the CUSTOMER table, nothing "seems" to happen in the PRINT table.  If I manually add a record in the PRINT table and enter the RECORD ID (the field the tables are related by) to match, then everything shows up.  But why doesn't the record add to the PRINT table automatically?  I check the boxes in the relationship for "Allow creation of records ..." and "Delete related records ..." and "Sort records" for both tables.  

            • 3. Re: ID Change With Auto Entry

              As you were told in your other thread on the same subject, that's not how FileMaker works.

              To add more detail to what's been posted already:

              "allow creation..."

              allows it. It does not make it something that happens automatically--which would not be a desirable thing in many cases. With that option, it's possible to create new records in the related table from the context of a record on a layout based on the table on the other side of the relationship. But it's merely possible, not an automatic thing. The typical use of this feature is to put a portal to the related table witht the "allow creation...." option specfied. If that option is enabled, you get a blank row in the portal where you can create a new record in the portal's table and FileMaker then copies over match field values to link that new portal record to the current layout record. A set field step performed from the context of this same layout that modifies data in a field of the related table can also create a record--exactly one such new record for each record in the layout's table.