I'm using neo4j, I have linux laptop with the server of neo4j, I did all configuration, so I can access from a mac to ip/browser, after that I'm trying to use that remotely from java project I'm using java-driver because neo4j-enbedded does not seems to support remote connections, so the questions is this how can I get all nodes and print the properties:
in the code below I have match(p:Book)return p
if I try to iterate "p" I'm not getting the properties, but I'm using like
match( p:Book) return p.title, then im able to see the values of title property,
I have 3 nodes books: Book( title:"book1", author:"author1" ) Book( title:"book2", author:"author2" ) Book( title:"book3", author:"author3" )
try ( Session session = Neo4jDriver.getInstance( URI.create( "bolt://10.0.0.17:7687" ),
"neo4j", "pass" ).session() )
{
StatementResult result = session.run( "match(p:Book) return p" );
while ( result.hasNext() )
{
Record res = result.next();
System.err.println(" --> "+res.get(0) );
} }
This is only printing something like:
->node<0>
->node<1>
->node<2>