Sam 山
Sam 山

Reputation: 42863

Language independent logic question

If one has three fields in a db that they are querying an object by.... One of these fields must always be an associations id. Concerning the other two fields "only one needs to be true"

What interpretation do you take or make of "only one needs to be true"?

Upvotes: 1

Views: 140

Answers (3)

djna
djna

Reputation: 55957

I'd read that as OR, only one needs to be true, but I won't object if the other is too.

If I meant EXCLUSIVE OR I would say "exactly one must be true".

However, the only way to be sure what was intended is to ask the author, who may well surprise you by telling you about yet a further condition ;-(

Upvotes: 3

Nathan Osman
Nathan Osman

Reputation: 73295

Well, I would read it as "one of the other two fields must match the search criterion". Beyond that, I would need more information.

Upvotes: 1

gnometorule
gnometorule

Reputation: 2139

I read this as meaning that the original search specified the condition that one field had to be assoc, plus 2 more conditions for the remaining two fields, but selection can be made if only one of these two (plus the assoc one) are true.

Upvotes: 1

Related Questions