How to return Multiple values from batch query

187 views
Skip to first unread message

Suhas

unread,
Jun 17, 2019, 6:49:52 AM6/17/19
to OrientDB
I'm trying to execute batch sql queries using PyOrient. 

It works all fine when returning one value. For instance,

begin;
let abcde = select * from ABC limit 5;
return $abcde

The result I get is a list of `pyorient.otypes.OrientRecord`. 

How does one return multiple values? I did try:

begin;
let abcde = select * from ABC limit 5; 
let bcde = select * from XYZ limit 10;
return [$bcde, $abcde]

I get a list containing two lists each containing `pyorient.otypes.OrientRecordLink`, whose hash (get_hash()) doesn't seem to make much sense. Eg: 
link.get_hash()
# returns #-2:163

How do I get a list of OrientRecords instead?

Suhas

unread,
Jun 17, 2019, 6:51:46 AM6/17/19
to OrientDB
OrientDB 3.0.15
Pyorient 1.5.5
Python 2.7
Reply all
Reply to author
Forward
0 new messages