Sign in to follow this  
Followers 0
davehoran

Invalid relationship when deleting records in converted databases

2 posts in this topic

I am working with a FileMaker application that was built and maintained in FMP4, and am trying to migrate into FMP11.  The files were converted first to .fp5, then imported into FMP11 and coverted to .fp7.  Overall the fields, layouts, scripts and security accounts survived the process with only some adjustments.

 

However, there is a problem with deleting records through a portal.  Our main DB layout contains a portal to another table in another .fp7 file.  The Relationships chart shows the relationship, and has the "Allow creation of records in this table via this relationship" and "Delete related records in this table when a record is deleted in the other table" checkboxes set for the portal source table.  New records can be added through the portal with no problem, but when trying to delete I get "This operation cannot be performed because one or more of the relationships between these tables are invalid."

 

Some particulars: The delete button is a container field from another table/file (not the portal source file).  The Relationship is keyed on an ID field, but that field is not shown in the portal; the Delete Portal Row script is preceded by a Go to Field[select/Perform] that references a name value field on the portal row.  The portal source table has Relationships that also set the "Allow creation of records in this table via this relationship" and "Delete related records in this table when a record is deleted in the other table" checkboxes - so deleting the portal row should also delete rows in that relationship (cascade).  Deletion doesn't even work when clicking the "Delete Record" button directly on the DB file. (I've seen on numerous occasions that this particular dialog is unhelpful and I agree - its no more helpful than the Check Engine light in your car).

 

I will also note that this delete functionality DID work in the conversion from .fp3 to .fp5: I can open these .fp5 files in FMP5 and the app works fine.

 

Any thoughts?

Share this post


Link to post
Share on other sites

Update:  I did find the culprit that was breaking the delete script.  There is a self-join that uses a key value of the table combined with the key value of another table.  I believe that when deleting this calculated field does not resolve and breaks the relationship.  I removed the relationship and the process worked fine.

 

I AM curious as to why this relationship worked in FM5: The delete process does complete with the relationship in place.  What changed in how self-joins work in FM11 versus FM5?

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0

  • Similar Content

    • By avo388
      Hello!
      I have re configuring the Research Notes Starter Solution - it works quite well for what I need. But I want to create a couple of extra tabs with portals, but I'm having trouble understanding the how the current IDs are being created (using a calculation) for the TYPE MATCH FIELD in the Data table for Notes, Documents and Media?
      Could anyone help me understand this? Should I just build it from scratch? I'm using Version 14.
      Thanks for your time.
    • By David Silverthorn
      I just purchased Scriptmaster Advanced, and entered in the license.
      When I attempt to generate a plugin, it gives the error:
      Server error: Unable to retrieve Scriptmaster license
      I've sent in a support request, but I wondered if anyone had experienced this error as well, and if it would be a simple fix from my end.
      Thanks!
      David Silverthorn

    • By ggt667
      I have a MacMini running macOS Sierra with FM11PA that works; however this FM11PA was installed when there was MacOS X 10.10 on the MacMini.
      Attempting to install FM11PA on my MB15R fails, well the installer appears to work fine( as pr attached image, ) but launching the app( as pr attached image ) tells me somebody has been fiddling with the installation and that I have to reinstall the application.


    • By fireandlight
      I've driven myself more or less crazy trying to figure this out on my own. The relationships themselves are rather simple: Each project has a list of questions. Each question has a person who created the question, and someone the question is assigned to. A question also has a number of responses associated with it which each have their own "creator".
      There are 3 main tables to cover: Questions, People, and Responses
      People consists of 3 fields: The UID, the person's name, and the person's email address Questions has 2 fields which relate to People: creatorID and assigneeID Responses has 1 field which relates to People: creatorID. The way the relationship graph is set up now, I have 3 instances of the People table that relate the UID field to the appropriate ID field in Questions or Responses as needed.
      What I want to happen is when I set an Assignee or Creator for a question or response, I want to use the corresponding record details from the People table - if one does not exist, then create a new one. Instead what happens is a get a new record in the people table every time. Even if I set the Layout field to give me a drop down of the existing values (and I use it to select one when, say, setting the assignee on a question) it still creates a new record. So confused... any help is much appreciated.
    • By Laura Griffin Long
      I would like to see if anyone could help me to verify if the problem I am having is a bug in Filemaker.  I have recently upgraded my network from Filemaker 13 to 14.  In 13 I did not experience this issue.  It seems that in Filemaker 14, when a particular Hindi character is pasted into a Filemaker field it crashes the database.  I have tested this on numerous machines within my network with the same result.  I am hoping that someone will run this simple test for me and report back if it happened to them as well.  I just need someone to create a database, create one text field.  Create a new record and paste this Hindi character in that field.  Then do a find and place your cursor in that field. At this point the database should crash.  If anyone can confirm this I would love to know, thanks! 
      Hindi character: क्स्ड (I will also attach a text file with the Hindi character in case something messes up when I post this...)
      hinid_error.txt