fragment of the mapping file:
"vertices": [
{
"index": "*",
"id": "@user",
"label": "USER",
"properties": {
"user": "@user"
}
},
code:
System.out.println(g.V().hasLabel("USER").id().limit(2).toList());
System.out.println(g.V().hasLabel("USER").limit(2).id().toList());
System.out.println(g.V().has("user").id().limit(2).toList());
System.out.println(g.V().has("user").limit(2).id().toList());
System.out.println(g.V().hasLabel("USER").valueMap().limit(2).toList());
System.out.println(g.V().hasLabel("USER").limit(2).valueMap().toList());
System.out.println(g.V().has("user").valueMap().limit(2).toList());
System.out.println(g.V().has("user").limit(2).valueMap().toList());
output:
[Tom, Rose]
[]
[Tom, Rose]
[Tom, Rose]
[{user=[Tom]}, {user=[Rose]}]
[]
[{user=[Tom]}, {user=[Rose]}]
[{user=[Tom]}, {user=[Rose]}]
Problem:
Why are these two queries that don't work?
g.V().hasLabel("USER").limit(2).id().toList()
g.V().hasLabel("USER").limit(2).valueMap().toList()
fragment of the mapping file:
code:
output:
Problem:
Why are these two queries that don't work?