Skip 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.

Open or Create Related Record

Featured Replies

I have two tables which are related. The Child table had the ID number of the parent table to link it. I would like to create a button the parent tables layout that would check to see if there was a related record and if there was to open it and if there was not to create one and then open it. At this point there will be only one record related. I have created this a a separate table because it is also related to another parent table. Can anyone help me with the script I might use on a button to do this?

Go to Related Record [ From table: “child”; Using layout: “child” (child) ] [ Show only related records ]

If [ Get ( LastError ) = "101" ]

Set Variable [ $Parent; Value:parent::id ]

Go to Layout [ “child” (child) ]

New Record/Request

Set Field [ child::parentid; $Parent ]

Go to Layout [ original layout ]

Go to Related Record [ From table: “child”; Using layout: “child” (child) ] [ Show only related records ]

End If

I have a similar question. I made a report layout on a db to track inventory. As it is now, I create my POs/invoices, then separately create a record in the inventory table for any kind of inventory that isn't already in there.

For example, if I write up an invoice for Converse - Men's shoes (converse being in the field SHOE and men's being in the field TYPE) and there is a record in the inventory table that has Converse - Men's, it will perfectly track that inventory. On the other hand if I would then create a purchase order for Converse - Children's, and there is no Converse - Children's record in the Inventory table, I would have to create it to track those shoes.

What I would like to do is have that record in inventory be created automatically if, and only if, it doesn't already exist. I have included the relationships I set up so far. Thanks.

DB_pic1.jpg

Create an account or sign in to comment

Important Information

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

Account

Navigation

Search

Search

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.