Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×
The Claris Museum: The Vault of FileMaker Antiquities at Claris Engage 2025! ×

Spontaneously combusting relationships


This topic is 7031 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

I only wish this post was about my love life.

I recently created a complex relationship to allow filtered viewing through a portal. It worked fine for a few days, then magically ceased to work. I made NO CHANGES to the system at all, in that time. Not even in another table or file. I checked the relationship again, and the filter globals that the relationship is based on, and EVERYTHING IS PERFECT. In fact, I compared it to my development copy, and everything is exactly the same (as far as this portal/relationship is concerned), though the development copy works. Also, I can't seem to use GTRR to this table, like I could also do even as recently as yesterday.

I tried reducing the relationship to simple ones to discover the error via process of elimination, and came up with this:

A = B

where A is a text field, and B is a text field containing multiple values

Previously, this relationship worked fine. However, now, B contains a value that exactly matches A, yet it does not show in the portal! Nothing shows in the portal, when I assign this relationship by itself. I've quintuple checked all the involved fields, and I'm using the correct TOC, but nothing seems to make sense. Can someone please explain why this perfectly good relationship went up in flames?

Thanks,

K

Posted

Well in order to work correctly as foreign key side the field urges to have an index, however it contains Get( functions will they not freshen accordingly, globals on foreign side of a relation won't work at all. So what needs to be done is to move all keying to primary side of the relation ...say you had a Get(CurrentDate would it behave the day you developed the solution ...but cease to work the following, because the drawing of the relational graph enforces the indexation.

I'm only guessing here!!!!!

--sd

Posted

Unfortunately, that does not apply in this case. The only global is local, not foreign, and there are no dates involved. The values involved are all straight, simple, one-word text strings. I wouldn't be this upset if it had never worked, but it worked perfectly for a few days before it went beserk.

Posted (edited)

Next issue on my debugging list is type mismatch, the keyfield should be the same, matching a number with a text makes jiffy logic rule.

Since you have a multilinekey must it be text on both sides! But since you're on 8 Advanced use the datainspector...

--sd

Edited by Guest
Posted

Checked and doublechecked! Again just now to be sure. And it all checks out. All involved fields are text. I'm starting to think I'm going insane. Here's the GTRR relationship to the same table that isn't working anymore, either:

Global = Unique Key

The GTRR script sets the Global to the Unique Key of the portal row (different relationship in the portal), and GTRRs, but to no avail. I Debugged with Data Viewer, and the Global is being populated with the correct Key, and the record with the corresponding Key does in fact exist. How does the relationship not work? I know Data can become corrupted, but can the database?

Posted

Something to try. I've always found that using Commit Record (used to be Exit Record) after setting a global field was a good idea before using it in a relationship.

Posted

Another thing to try is to rebuild it from scratch sans bells and whistles ...to eliminate file corruption.

Another thing is, why do you use a global in the first place - they're hardly manditory in any solution just perhaps convenient, try turning it an ordinary field.

--sd

Posted

I tried adding the commit step, still no luck. As for rebuilding it...It's a small part of a huge solution, I have no desire to rebuild it until all else fails.

As for globals, I have a dynamic portal, and the globals provide the filters. The way the solution is set up (I haven't created it, I just started working on it a month ago) there is a main file with all the scripts, layouts, relationships, etc, but with no data. Just globals that relate to the actual data files. This makes it very easy to perform major updates, as only about 5% of all changes and additions are made on the data files, and the main file can just be replaced with every new release.

Posted

Oh no...please reassure me that this is not, against all appearances, a sign of data corruption:

I right-click on the Unique Key field (in the actual table, not through a portal), and select Find Matching Records. Result: NO RECORDS FOUND. How can this happen??? Short of corruption, this should be impossible, or am I wrong?

Posted

Please correct me network gurus, but isn't it so that making both filemaker native hosting work simultainously with OS level filesharing is one of the most common ways to corrupt a file???

--sd

Posted

Try reforcing your index. Open your Define Fields in your portal table. Find the field which is the key for that table. To the right of Type under Options, does it say indexed? If not, select the field and go to Options. What is the indexing set on? It shouod be minimal.

If it is, change it to an unstored calc and leave close Field Definitions then go back and change it back to indexed again. One other thing to check ... in your graph, open the relationship dialog and make sure both fields are being selected and appear appropriately.

Don't assume corruption if you haven't had the file trash on you. Attach it here first. It could be broken in the layout specification. There are several things you can check. I would be more than happy to check it for you. I've become very good at finding wonkies ... I create them all the time. :wink2:

L

Posted

Gotterdamerung!*

Of all things, I never thought to spot this little detail. There's no corruption...unless you happen to be a language purist.

For whatever reason, the involved files were indexed in German. This would have been almost funny, if I had just made them, or changed them by accident. But I'm the only one with developer priveleges and I hadn't touched that system in two days, during which it worked fine. This spontaneous language change is somewhat disturbing, but a huge relief all the same, compared to the other possibilities.

Thank you all for your help, I really appreciate it, as always!

K

*Yes, I know what it actually means. But I feel like I'm constantly warring with the FileMaker gods, so I feel it appropriate :

This topic is 7031 days old. Please don't post here. Open a new topic instead.

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
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.