Head's Up! These forums are read-only. All users and content have migrated. Please join us at community.neo4j.com.
06-10-2020 07:03 PM
H All,
I need to check one array against another in neo4j. Basically I am trying to check the permission against which user inherit from his role or group
match (u:user)-[:MEMBER_OF]->(r:role) where u.uid = 46713
with u as usr, r as rol
match (usr)-[mog:MEMBER_OF_GROUP | CREATED_GROUP]->(g:group)
with usr, rol, g, mog
call apoc.when(mog.inherit = true, "RETURN rol as val", "RETURN mog as val", {mog:mog, rol:rol})
YIELD value
with value,g
match (g)-[can:CAN_ACCESS]->(n) where n.name = "hello"
with can, value as v, g
call apoc.when(size(can.directoryPermission) > 0, "RETURN can.directoryPermission as directoryPermission", "RETURN can.documentPermission as documentPermission", {can:can})
YIELD value
with value as entityPermission, v as permissions
return entityPermission, permissions
result ->
need to check this entityPermission with permission.
thanks
Meet
All the sessions of the conference are now available online