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.

if/case functions with related files

Featured Replies

I'm trying to sum a field in one database (CTA) in a related db (Reviewers). I only want to total the Primary Reviewers from a particular group: those that are marked "Review (send)." I tried the following, but it only adds up the Primary Reviewers if ALL of the records are marked that way, otherwise, it's blank.

Case(CTAone::AppStatus = "Review (send)", Count(CTAone::Primary Reviewer))

Maybe it should be an If function?

thanks for suggestions

CWH, we meet again! cool.gif To answer your hypothesis, If and Case are essentially the same. But forget that. Here's the deal: you have shot yourself in the foot by naming your field "Review (send)." Fields with names that include parentheses can't be used in calculations, and we need to Count() this field. So I'm renaming it reviewSend. Now then...

Count(CTAone::reviewSend)

  • Author

Fitch, thanks for your efforts on my behalf once again. Unfortunately, I wasn't clear -- the field is AppStaus and Review(send) is text from a value list. Even when I change the text to ReviewYes, it's still not counting the primary reviewer field for at least one record.

Ah, I wasn't looking closely enough. You described it just fine the first time. I see now. This is a common situation. When you want to count a text field based on its contents, you have to create a calculation field, in this case we'll call it reviewSend:

AppStatus = "Review (send)"

That's a field in the CTA file. The calc will return a 1 if it's true. Then you can count or perhaps total it in the Reviewers file as in my last post:

Total(CTAone::reviewSend)

  • Author

Unfortunately, I don't think that will give me what I need, which is to tabulate each type of review that each reviewer is assigned, but only if App status=Reviewsend. So I think there has to be an If function involved, but the one I constructed has the problem I indicated above. If any of the applications assigned to a particular reviewer do not = Reviewsend, then it doesn't count any of them.

You're going to need 3 calculated fields in the CTA file:

PrimarySend...

Case(AppStatus = "Review (send)", Primary Reviewer)

SecondarySend...

Case(AppStatus = "Review (send)", Secondary Reviewer)

TertiarySend...

Case(AppStatus = "Review (send)", Tertiary Reviewer)

Now, in the Reviewers file, instead of this:

Count(CTAone::Primary Reviewer)

...do this:

Count(CTAone::PrimarySend)

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.