arangosh> db._create("vertex");
[ArangoCollection 7438, "vertex" (type document, status loaded)]
arangosh> db._createEdgeCollection("relation");
[ArangoCollection 7440, "relation" (type edge, status loaded)]
arangosh> v1 = db.vertex.insert({ name : "vertex 1" });
{
"_id" : "vertex/7443",
"_key" : "7443",
"_rev" : "_VsbzMf----"
}
arangosh> v2 = db.vertex.insert({ name : "vertex 2" });
{
"_id" : "vertex/7447",
"_key" : "7447",
"_rev" : "_VsbzMf---_"
}
arangosh> e1 = db.relation.insert(v1, v2, { label : "knows" });
{
"_id" : "relation/7450",
"_key" : "7450",
"_rev" : "_VsbzMfC---"
}
arangosh> db._document(e1);
{
"_key" : "7450",
"_id" : "relation/7450",
"_from" : "vertex/7443",
"_to" : "vertex/7447",
"_rev" : "_VsbzMfC---",
"label" : "knows"
}