> result.iterator() will give you an iterator of type Map<String,Object> where each map represents a "row"- the String is the column name and value is the column value (p in your case).
> If you just want the results of a single column, you can do result.columnAs("p") which, in your case will give you an Iterator<Node>.
> -Luanne
> On Wed, May 30, 2012 at 8:14 AM, M.Alipour <mahdialipour2...@gmail.com> wrote:
> Hi,
> I use this code in Cypher:
> String qq="start n=node("+id+") match p=(n)-[?*]->(n) return p";
> ExecutionEngine engine = new ExecutionEngine( graphDb );
> ExecutionResult result = engine.execute(qq);
> System.out.print("\n"+result.dumpToString());
> and after running, i get:
> +--------+
> | p |
> +--------+
> | <null> |
> +--------+
> 1 row, 1 ms
> my problem: how can i handle returned value in this output? What is
> the type of the Cypher output?Is table? Is string? or .... How i can
> process Cypher output?
> for example, i want this Pseudocode:
> if output==Null then print "output is null"
> if output=="myOutput" print "ok"
> Thanks.