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.

Shouldnt be so hard... i must be missing somehting.

Featured Replies

Heres the problem, i am pretty sure i am doing everything correct but i cant get this to work.

There are two layouts.

There are two tables.

Layout 1 - uses table 1

Layout 2 - uses table 2

I want to display a value on layout 2 from table 1. A relationship is required because layout 2 is associated with table2 not table 1.

Primary key from table 1 is set to auto serial. I have a 1 to many relationship from table 1 primary key going to the foreign key of table 2.

This should allow me to display values from table 1 on layout 2 which is associated with layout 2. correct?

On layout 2 i have a field that is set to display values from primary key field from table 1. When in layout mode it looks like it is set up right as it shows :(:table1ID.pk. The problem is that when in brows mode the field is empty.

Any ideas?

You would also need a value in a foreign key in table 2 which was exactly the same value as the value in the primary key in table 1. You must have this foreign key field already, else what did you build the relationship with? But did you put a value in it? It takes 2 keys with identical values (or containing an identical value in one of its multiple lines) to make a relationship, one on each side.

  • Author

Yes i have the foreign key field already. However, i did not have a value in it. What would be the best way to make sure it always has the same value in it as the primary key from table1?

Go here:

http://fmforums.com/forum/showtopic.php?tid/190391/post/267983/hl//fromsearch/1/#267983

hth

  • Author

ok, i understand how to give the fk a value based on the first table. In that example the user selects the fk to use.

I need filemaker to automatical take the value out of the primary key from table 1 and use it as the foregn key in table 2. I am not sure how to pass this value over without the user needing to do anything. This value will change when the record on table 1 is change.

Well, you can script it; put the current table1 primary key into a Variable (or global field), then go to the layout of table2, create a new record, set the table1_fk foreign key to the captured value, commit record, then return.

Or you can enter data in a portal in table1, with the relationship* allowing creation of related records.

*Based on the table1 key on both sides, table1::table1_pk = table2::table1_fk

The phrase "without the user needing to do anything" is misleading; the user always has to do something, enter data or hit a button.

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.