One way would be to set up a calc field with a Le statement.
cur (List( Table::Field2check));
if (ValueCount(cur) >0;"yes";"no"))
This will create a list of items so it checks all fields in the relationship, and returns a yes for 1 or more values.
The catch, as an unstored calculation this may be a bit slow since it has ti check all records in the related table. You can do it as a stored calc, but then you have to come up with a way to trigger an update.
I assume you do have a relationship between Customer & Purchase by CustomerID
not IsEmpty ( Cust_Purch::CustID ) ; "Yes" ; "No" )
Your suggestion worked wonderfully. If you could let me know if you think of a way to calculate it as a stored calculation, I would really appreciate it. But thanks so much. Works great.
The trick is to add a dependany in the local record and change the
So if you add a field say upd and the field to the let section of formula. The have a script replace the value of upd for all records in the found set. FileMaker will update all of the fields.
The last part is to change the Field to an autoenter calk. Make sure you uncheck "Do Not evaluate if all referenced fields are empty" on the formula screen and uncheck "Do Not replace existing value if any" This will ensure that the field updates when you change the valueof upd.
You could trigger the update script as part of the open layout script so that it refreshes once when the layout is opened.