Fetch vertices from a range using Graph API

96 views
Skip to first unread message

Kalatheeswaran TM

unread,
Jul 2, 2015, 12:14:18 PM7/2/15
to orient-...@googlegroups.com
Hi,

I need to fetch a specified set of newly inserted vertices from a OrientDB graph to create edges.

If I make use of the getVerticesOfClass("ClassName") method in OrientBaseGraph fetches all the vertices (vertices previously inserted and for those edges have been created).

How to fetch the vertices from the range specified?

Thanks & Regards
Kalatheeswaran

Giulia Brignoli

unread,
Jul 3, 2015, 3:02:32 AM7/3/15
to orient-...@googlegroups.com
Hi Kalatheeswaran,

to fetch the vertices from the range specified, you can used a query.
For example:
 
graph.command(new OSQLSynchQuery <Vertex> ("select from V where <whatYouWant>")).execute();

Bye,
Giulia

Kalatheeswaran Thiru Meganathan

unread,
Jul 3, 2015, 5:21:18 AM7/3/15
to orient-...@googlegroups.com

Thanks very much

--

---
You received this message because you are subscribed to a topic in the Google Groups "OrientDB" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/orient-database/S7-gaVdapjY/unsubscribe.
To unsubscribe from this group and all its topics, send an email to orient-databa...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Kalatheeswaran TM

unread,
Jul 8, 2015, 9:16:38 AM7/8/15
to orient-...@googlegroups.com
Hi,

But when I do that I need to keep a large set of vertices in the iterable vertex, which may consume a lot of RAM and slow down the application.
Is there any other way ?

Thanks,

Kalatheeswaran


 

nagaraja sosale ramaswamy

unread,
Jul 8, 2015, 9:44:32 AM7/8/15
to orient-...@googlegroups.com
you might want to consider using a fetch plan to limit the amount of data that is fetched eagerly, thereby reducing the memory usage at the client.

Kalatheeswaran TM

unread,
Jul 8, 2015, 9:54:59 AM7/8/15
to orient-...@googlegroups.com
Thanks for your reply
But I am using a plocal connection. It is still slow

machak

unread,
Jul 8, 2015, 10:02:01 AM7/8/15
to orient-...@googlegroups.com
On Wednesday, July 8, 2015 at 3:54:59 PM UTC+2, Kalatheeswaran TM wrote:
Thanks for your reply
But I am using a plocal connection. It is still slow

cheers
/m
Reply all
Reply to author
Forward
0 new messages