Jump to content

This topic is 5390 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

I'm trying to find out if there is a way to determine if a parent record has any child records via a calculation. I know I can do this by creating a script and setting a variable of the parent record and then doing a search on the child table, but to me that just seems like a convoluted way to go about this.

Posted

... but to me that just seems like a convoluted way to go about this.

I would agree. You can have a searchable numeric field, instead.

In your Parent table, create a calculation resulting as a Number. Modify the following calc to fit your relationship and field ...

Count ( childrelationship::IDfield )

It's critical that the field being "counted" always have a value. Most developers use the ID field.

Hope this helps!

This topic is 5390 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

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