I can\'t seem to find a pointer in the right direction, I am not even sure what the terms are that I should be researching but countless hours of googling seem to be spinning me
These kinds of queries are often presented as an OR
ed array of AND
ed clauses. That is, a tabular format in which you read across multiple conditions AND
ed together, and then read down to OR
them. That leads to some repetition of conditions, but is easy for users to read, write, and understand. Your sample ((Sex == Male AND Age == 25) OR (Sex == Female AND Status == Single)) AND IQ > 120
would look like
Sex == Male & Age == 25 & IQ > 120
Sex == Female & Status == Single & IQ > 120