Fetch plan - inability to exlude property from eager fetch

Skip to first unread message

Jan Plaček

Sep 29, 2015, 10:41:55 AM9/29/15
to orient-...@googlegroups.com
I think there is a flaw in fetch plan design (or implementation), the problem is that these two following fetch plans return exactly the same result:


In both cases IDs contained in these collections will be expanded into actual records (they're eagerly fetched) and
any "ridCollection" nested in these expanded records are not further more expanded (also in both cases), result will contain:

ridCollection: [{...}, {...}]

In consequence there is no way how to exclude property from being eagerly fetched and keeping that property as a collection of RIDs.
(I am not talking about exluding the property completely from the result, which can be achieved by ridCollection:-2)  

I think thats exactly what the fetch plan "ridCollection:0" supposed to do instead:

ridCollection:0 -> ridCollection: ["#12:0","#12:1"] (basically the same as not using fetch plan, but can be used with multiple rules like: *:-1 orders:0) 

ridCollection:1 -> ridCollection: [{...}, {...}] (eagerly fetched expanded records)

ridCollection:-2 -> the ridCollection property is completely omited in result  

Using OrientDB 2.1.1
Reply all
Reply to author
0 new messages