我有多条记录
name1 employee building1
name2 employee building1
name3 manager building1
name4 manager building1
name5 employee building2
name4 manager building2
我想获取building1
访问权限但未获得building2
访问权限的所有经理。
任何建议。
答案 0 :(得分:0)
试试这个,
(field1:manager AND field2:building1)AND(NOT(field1:manager AND field2:building2))
注意:检查语法。
这意味着fetch(有权访问building1的经理)和(经理无权访问building2) 或
(field1:manager AND field2:building1 AND(NOT(field2:building2)))
经理可以访问building1而不是building2