Consider the following sample collections:
*User (vertex)*
[
{"name": "Bob"},
{"name": "Rob"},
{"name": "Tim"},
{"name": "Jim"},
...
]
*Role (vertex)*
[ {"role": "Basic"},
{"role": "Admin"},
]
*UserRole (edge)*
[
{
"_from": "User/...", # (Bob)
"_to": "Role/...", # (Basic)
"role_name": "Basic",
},{
"_from": "User/...", # (Tim)
"_to": "Role/...", # (Admin)
"role_name": "Admin",
},
...
]
The docs seem to indicate that you can use Views for things outside of text
analysis, but I can't figure out how. Specifically, with the sample
collections I'm looking to
1. Create view of UserRole that contains only a subset of edges (e.g.
only ones that have .role_name = "Admin"). [This is what I mean by
"filtering" view in the subject.]
2. Create view of UserRole that automatically provides the "role_name"
from the ._to vertex document's attribute and doesn't require me to store
it twice (once in Role.role, and again in UserRole.role_name). [This is
what I mean by "joining" view in the subject.]
The goal is model the data as normalized as possible, but provider these
"helper" type views that I can use as Vertex/Edge collections for graphs.
Is this possible?
Thanks in advance.
--
You received this message because you are subscribed to the Google Groups
"ArangoDB" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.