Hi, I need to find all the files directly shared with the user or via a group created by someone else.
I tried the following query it is giving results, however, if no file has been shared directly with the user or via group then I see three nodes with no relation
it might be possible the same file is shared directly to the user and with the group and the user is part of that group too. In this case, I need a file which is directly shared with the user not the group one.
I have also attached the dump for our database
match (u:user) where u.ohrid = "120" match (f:file) optional match (u)-[mg:MEMBER_OF_GROUP|CREATED_GROUP]->(g:group)<-[fswg:FILE_SHARED_WITH_GROUP]-(f) optional match (f)-[fsw:FILE_SHARED_WITH]->(u) return u, mg,fswg, g, fsw, f