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.

Featured Replies

The TO "Companies-JoinCP-People" manages a many-to-many relationship.

Setting the Data Viewer to:

Count (Companies-JoinCP-People)

returns an accurate count no matter what record I jump to.

However, when used in an If statement it does not.

If(count(Companies-JoinCP-People) = 1

skips, does not enter the If statement when it should.

Exactly the same thing happens if I create an unstored calc field with the formula "count(Companies-JoinCP-People)". It displays accurately in the Data Viewer but doesn't function properly in a scripted If statement.

This is in FMP11. What am I misunderstanding?

Kind regards,

You are probably in the wrong context when your script gets to it. It's hard to say for sure, since Count (Companies-JoinCP-People) is not a valid expression in any case.

The TO "Companies-JoinCP-People" manages a many-to-many relationship.

Setting the Data Viewer to:

Count (Companies-JoinCP-People)

returns an accurate count no matter what record I jump to.

However, when used in an If statement it does not.

If(count(Companies-JoinCP-People) = 1

skips, does not enter the If statement when it should.

Exactly the same thing happens if I create an unstored calc field with the formula "count(Companies-JoinCP-People)". It displays accurately in the Data Viewer but doesn't function properly in a scripted If statement.

This is in FMP11. What am I misunderstanding?

Kind regards,

It is unclear what you're doing. The calc you describe is not complete, so of course it won't be accepted.

If(count(Companies-JoinCP-People) = 1 ; trueValue; falseValue)

  • Author

Bruce, you're right. Should be

count(Companies-JoinCP-People::)__PeopleID)

Count(Companies-JoinCP-People::)__PeopleID)

is not a valid expression either: the table name contains a hyphen.

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.