Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot make any examples ran #18

Open
dmikov opened this issue Apr 18, 2016 · 4 comments
Open

Cannot make any examples ran #18

dmikov opened this issue Apr 18, 2016 · 4 comments

Comments

@dmikov
Copy link

dmikov commented Apr 18, 2016

Maybe I am doing something wrong or the versions are out of synch. I am using the latest binaries you have with Neo4j 2.3.3

The first graph traversal example is failing load with following error:

{
"errormessage": "javax.script.ScriptException: groovy.lang.MissingMethodException: No signature of method: org.apache.tinkerpop.gremlin.process.traversal.dsl.graph.GraphTraversalSource.loadGraphML() is applicable for argument types: (java.lang.String) values: [https://raw.githubusercontent.com/tinkerpop/gremlin/2.5.0/data/graph-example-2.xml]"
"success": false
}

And consumption of existing data return some results, but trying to return a property gives following error.

{
"errormessage": "javax.script.ScriptException: groovy.lang.MissingPropertyException: No such property: F01 for class: org.apache.tinkerpop.gremlin.process.traversal.dsl.graph.DefaultGraphTraversal"
"success": false
}

The script used is g.V().hasLabel('RecordEmployee').has('F01','Philip').F01

@dkuppitz
Copy link
Member

Try:

g.V().hasLabel('RecordEmployee').has('F01','Philip').values('F01')

Or simply:

g.V().has('RecordEmployee','F01','Philip').values('F01')

@dmikov
Copy link
Author

dmikov commented Apr 18, 2016

Thank you very much. That made it kinda work. But where can I find documentation on this? Both readme.md and gremlin site in the links shows dotted notation no values pipe also this one http://neo4j-contrib.github.io/gremlin-plugin/#rest-api-sort-a-result-using-raw-groovy-operations . I need to know the syntax to return map or something useful. Right now it is

{
"success": true
"results": [4]
0:  "Fry"
1:  "Philip"
2:  "Leela"
3:  "Turanga"
}

For two fields from two nodes.
g.V().hasLabel('RecordEmployee').values('F01','F02')

@dmikov
Copy link
Author

dmikov commented Apr 18, 2016

I am reading on Tinkerpop 3, it seems that is what this syntax is?

@dkuppitz
Copy link
Member

Yes, the latest docs can always be found under http://www.tinkerpop.com.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants