Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Bloody Beginner - Please help with Relationship and Portal

Featured Replies

  • Newbies

Good evening everyone,

I am a complete new starter, studying Filemaker and a 980 page book for almost 2 weeks. Please excuse this probably "less in two minutes answer to my question" question:

As part of a contact management database, I have created tables company, contacts (people), adresses, telephone, and email. Now I want to create a layout based on company, which displays a full list of company records in a portal. Next to the portal all fields in the company table should be displayed, with all related telephone and email addresses (shown in seperate portals in the same layout). An additional portal in the same layout is then displaying all related contacts, again with merge fields next to the portal showing all fields of the contact table and (again as portals) all related telephone numbers, email and addresses.

Accomplishment so far:

To display all companies in a layout, I have created a cartesian (X) occurrence between company and company as a self join, to display all company names in a portal.

In the company table I have created a calculation field, which also acts as a button, to retrieve the clicked KeyID, and to highlight the clicked row.

And here are my problems:

Although is works in the Script Debugger, the KeyID is not retrieved, and the selected row of data is not highlighted. Again, when running it through the debugger, it clearly shows that the correct KeyID is retrieved (and the clicked row is highlighted with a the graphic in the container field of the button).

Next problem, the related company details, are not changing, although the KeyID changes in the debugger. It seems that they "stick" to the layout.

Question: How should I set up the relationship overall? The cartesian related table is used for the company listing in the layout "companies", the tables contacts, address, telephone and email are related with equi joins to companies and contacts

Can any of you please give a good advice?

many thanks!

Sascha

In the company table I have created a calculation field, which also acts as a button, to retrieve the clicked KeyID

This doesn't sound quite right. How is a calculation field supposed to respond to you clicking on a portal row? Something like this is possible, but it requires a fairly advanced technique. If I were you I'd just use the button to either set a field with global storage to the key, and show the "selected company" as related data. Or (probably easier), use the button to Find the company record clicked on, which would automatically show its data.

But I don't really see the need for the portal in the first place. What's wrong with a standard Find?

  • Author
  • Newbies

hmmmm, good point. Let me think how that would relate and try the search option connected to the button.

Any idea why a script works in the debugger, and not under normal circumstances?

Thanks for the help!!

Sascha

I am guessing the purpose is to have a side bar listing all companies as a navigation tool. I think a global field is indeed best suited for this - a simple demo of the technique can be found here:

http://www.fmforums.com/forum/showpost.php?post/289092/

  • Author
  • Newbies

Thanks for the example! Why does it look so easy in that? I try to adjust it to my file.

Yes, the table is for navigation purposes. normal search in list view doesn't appeal too much to my eye. But I will try now all techniques.

If I may, I will come back to you once this problem is further "deveoped" - better solved.

Thanks both of you! Thank god it is still daytime in the US, while everyone here is asleep.

Sascha

Why does it look so easy in that?

LOL, maybe because it is?

Create an account or sign in to comment

Important Information

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

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.