I believe both methos are almost equal. As I understand developers
translate java method calls to sql then.
Did you try this where userId is a java.lang.String?
this.txGraph.command(new OCommandSQL("select * from Users where userId =
?")).execute(userId);
On Monday, 14 July 2014 11:31:32 UTC+1, Tiziano Fortin wrote:
>
> Hi luca,
>
> I've this java code:
>
> String userId;
> Iterable<Vertex> vertexes = this.txGraph.command(new OCommandSQL("select *
> from Users where userId = '" + userId + "'")).execute();
> Vertex v = vertexes.iterator().next();
>
> but I obtain this error on vertexes.iterator().next() :
>
> java.util.NoSuchElementException
>
> at
> com.tinkerpop.blueprints.impls.orient.OrientDynaElementIterator.next(OrientDynaElementIterator.java:31)
>
> at
> myproject.adapter.persistence.OrientAdapterImpl.getUserData(OrientAdapterImpl.java:56)
>
>
> In OrientStudio I retrieve correctly the result with same query. How i can
> fix it?
>
--
---
You received this message because you are subscribed to the Google Groups
"OrientDB" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.