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.

evaluate with empty fields

Featured Replies

I have a calculation "prev_st_1" field that is used in a relationship so that "st" can be calculated.

because of the relationship structure that "prev_st_1" uses to calculate the first x records have no relations and thus return a ?

I need this field to return a 0 if one of the referenced fields is empty, so that the other relationship can work.

My current work around is to create a second calc field "prev_st_2" which looks at "prev_st_1" and if it is empty returns a 0, else returns the value.

any ideas or is my work around as good as it gets?

Perhaps you can post your calc? I dont quite understand what your orig calc is even for.

  • Author

Let ([

n = Count(equipment_list_ST_aux::pk_equipment_list_line_id) ;

all = equipment_list_ST_aux::pk_equipment_list_line_id ;

prev = GetNthRecord ( all ; If (n>0;n;0) )];







prev



)

Try:


Let ( [ n = Count(equipment_list_ST_aux::pk_equipment_list_line_id);

        all = equipment_list_ST_aux::pk_equipment_list_line_id;

        prev = Case ( n; GetNthRecord ( all; n ); 0 ) 

      ]; prev

    )

* Edit - typo and added formatting

Edited by Guest
Reason for edit: added closing paran and formatting

  • Author

perfect - with an extra ) snuck in!! :

many thanks

Create an account or sign in to comment

Important Information

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

Account

Navigation

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.