Jump to content
Server Maintenance This Week. ×

Multiple conditioned calculated value


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

Recommended Posts

Hi people!

I'm trying to set up multiple conditioned calculated value to a field using Case or If functions but It gets too complicated for my current filemaker skill level.

Here's the deal:

- I have field SUPPLEMENTATION that should have auto-enter text value based on the calculation which includes other 4 fields ( VITAMINS MORNING; VITAMINS EVENING; MINERALS MORNING; MINERALS EVENING) and multiple conditions

- When field VITAMINS MORNING or/and VITAMINS EVENING is not empty, value of field SUPPLEMENTATION is "Swanson" (Condition 1)

- When field MINERALS MORNING or/and MINERALS EVENING is not empty, value of field SUPPLEMENTATION is  "Now" (Condition 2)

This one I managed because conditions exclude one another but from here on it gets complicated because condition 1 and 2 are combined.

When field VITAMINS MORNING or/and  VITAMINS EVENING is not empty in combination with not empty field MINERALS MORNING or/and  MINERALS EVENING, value of field SUPPLEMENTATION is "Swanson and Now" (Condition 3)

Final calculation should include all 3 possible conditions.

This one is simply beyond my comprehension.

Please help!

Link to comment
Share on other sites

1 hour ago, Sinky said:

This one I managed because conditions exclude one another

I don't see how they "exclude one another". They can both be false or true at the same time. 

Anyway, I think you want something like:

Substitute (
List (
If (not IsEmpty ( VITAMINS MORNING & VITAMINS EVENING ) ; "Swanson" ) ;
If (not IsEmpty ( MINERALS MORNING & MINERALS EVENING ) ; "Now" ) 
) ;
¶ ; " and " )

This is assuming I understood correctly what you mean by "or/and"; such expression is suitable for use in a contract, but it is ambiguous in the context of logic.

 

2 hours ago, Sinky said:

I have field SUPPLEMENTATION that should have auto-enter text value based on the calculation

What not simply make it a calculation field? 

Link to comment
Share on other sites

This topic is 1603 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.