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.

Scripted delete record best practice

Featured Replies

What steps do you take when scripting a delete record both in general and specifically when doing a go to related record?

Edited by Guest

Making sure that you have the record(s) that you definitely want to delete as the found set. You should make sure that you properly error trap, especially when using GTRR as if there are none, you could be deleting out parent records.

  • Author

What error trapping precautions do you take? Check the parent table? Check the found count?

Edited by Guest

First I check to see if there is a related record.

If [ IsEmpty ( Child::ChildID ) ]

Set Error Capture [On]

Go to Related Records [show related only]

If [ Get (LastError) ]

Show Custom Dialog ["Error"]

Else

do something

End If

This is okay if you are using GTRR for the current parent record.

However, if you are trying to match on the found set, things are a little different for capturing the error code.

If none of the parent records have matching children records, then it should result in a 401 error.

If the first parent record does not have related records but some of the other parent records do, then it will result in a 101 error.

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.