Returning all RIDs in a multi-record linkmap path

17 views
Skip to first unread message

Eric24

unread,
Dec 31, 2017, 12:21:43 PM12/31/17
to OrientDB
Using this example from the documentation on time-series data:

SELECT expand( month[3].day[20].hour[10].logs ) FROM Year WHERE year = "2012"

How would I get all of the RIDs (as a list or record set) that were "traversed" by this query? I realize I can do a TRAVERSE, but the problem is that this requires a read of all the records to the desired depth, even using a limiting WHILE clause to reduce the actual result set, so that's not very efficient as the number of records increases.

Since ODB needs to actually "traverse" each of the records as it "walks down" the list of links, it seems like it should be able to "know" what records it passed by. Is this information available?

I did try using the $path variable, but it only works with a TRAVERSE, not a SELECT.

I've also tried doing this with a MATCH, but I've not been successful on that front either.

Reply all
Reply to author
Forward
0 new messages