4 Replies Latest reply on Apr 23, 2012 6:56 AM by mathematrucker

# multi-criteria relationship using logical "OR" operator

### Title

multi-criteria relationship using logical "OR" operator

### Post

Admittedly I've been a FileMaker user for 20 years and the evident lack of this feature has never affected me until now. However once it did, I found myself really annoyed that FileMaker has never added it to its product. (The new features nowadays mostly seem to be fluffy things like more pre-defined layouts as opposed to true expansions in functionality.)

I sorely miss being able to put a string of "OR"s between all of my relationship criteria instead of the string of "AND"s that appears automatically. The ultimate would of course be the ability to create complex criteria involving parenthesized subexpressions, but even just the ability to replace all the "AND"s with "OR"s would have saved me an absolute MOUNTAIN of workaround coding.

I briefly thought Boole might be able to save me, since (field a = field b) OR (field c = field d) is the same as NOT [(field a not-equal field b) AND (field c not-equal field d)], but is there any way to achieve that "NOT" in front? I don't think so. Portal-filtering would be of no use because I need these results for internal calculations, not portal displays.

• ###### 1. Re: multi-criteria relationship using logical "OR" operator

Could you not have two relationships, one based on FieldA = FieldB, and the second on FieldC = Field D, and them in the calculations, have them prefixed with a case Statement:

Case (

FieldA = FieldB OR FieldC = FieldD ; DoThis, etc

)

• ###### 2. Re: multi-criteria relationship using logical "OR" operator
`Maybe I do not understand, but a multi-predicate relationship should be a solution for you.`
`You'll need to set a field with two values from one side of the relationship to get the OR.`
• ###### 3. Re: multi-criteria relationship using logical "OR" operator

I played with that idea before I posted, and I couldn't get my head around whether that provided the right combination of AND and OR - but I am sure raybaudi is right!

raybaudi's point is that if you have a field on one side of the relationship that has the return-separated values that in one record has these values

a
b

and another record with the values

c
d

and a field on the other side of the relationship with the values

a
c
e
g
i

both will match for a OR c.

• ###### 4. Re: multi-criteria relationship using logical "OR" operator

Thanks everyone!  Sure enough, return-separated values in a match field do the trick!