与语言无关的逻辑问题
如果一个数据库中有三个字段,他们通过...查询一个对象。 这些字段之一必须始终是关联 ID。 关于其他两个字段“只有一个需要为真”
您对“只有一个需要为真”有何解释?
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"?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
我将其解读为OR,只需其中一个为真,但如果另一个也为真,我也不会反对。
如果我的意思是排他或,我会说“恰好一个必须是真的”。
然而,确定其意图的唯一方法是询问作者,他可能会告诉您进一步的条件,让您感到惊讶;-(
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 ;-(
我认为这意味着原始搜索指定了一个字段必须是 assoc 的条件,再加上其余两个字段的 2 个条件,但如果只有这两个字段之一(加上 assoc 一个)为真,则可以进行选择。
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.
好吧,我会将其解读为“其他两个字段之一必须符合搜索条件”。除此之外,我还需要更多信息。
Well, I would read it as "one of the other two fields must match the search criterion". Beyond that, I would need more information.