Hi Madhu, please can you unactivate shallow collection setting in studio (see previous post)?
Lvc@ On 14 April 2014 14:11, madhu <[email protected]> wrote: > Lvc@, > > The Raw panel shows the following. > > { > "result": [ > { > "@type": "d", > "@version": 0, > "compositeIndexUsed": 1, > "involvedIndexes": [ > 1 > ], > "fullySortedByIndex": false, > "indexIsUsedInOrderBy": false, > "current": "#9:229298", > "evaluated": 232492, > "orderByElapsed": 281, > "elapsed": 21748.035, > "resultType": "collection", > "resultSize": 300, > "@fieldTypes": > "compositeIndexUsed=l,involvedIndexes=e,evaluated=l,orderByElapsed=l,elapsed=f" > } > ], > "notification": "Query executed in 21.826 sec. Returned 1 record(s)" > > And indexes created are the following... > > *Name * > > *Type * > > *Class * > > *Properties * > > *Engine * > > ___exportImportRIDMap > > DICTIONARY_HASH_INDEX > > [undefined] > > SBTREE > > dictionary > > DICTIONARY > > [undefined] > > SBTREE > > ORole.name > > UNIQUE > > ORole > > [name] > > SBTREE > > OUser.name > > UNIQUE > > OUser > > [name] > > SBTREE > > V.ICON_TYPE > > NOTUNIQUE > > V > > [ICON_TYPE] > > SBTREE > > V.SEV_INWIN > > NOTUNIQUE > > V > > [SEV_INWIN] > > SBTREE > > V.STATE > > NOTUNIQUE > > V > > [STATE] > > SBTREE > > V_IP > > NOTUNIQUE > > V > > [IP] > > SBTREE > > V_LINK_TYPE > > NOTUNIQUE > > V > > [LINK_TYPE] > > SBTREE > > V_SQLID > > NOTUNIQUE > > V > > [SQLID] > > SBTREE > > V_TOPO_TYPE > > NOTUNIQUE > > V > > [TOPO_TYPE] > > SBTREE > > V_UUID > > NOTUNIQUE > > V > > [UUID] > > SBTREE > > Individual indexes created on the properties which are involved in the > query > 1) STATE 2) SEV_INWIN 3) ICON_TYPE > > Even this way also I am not able to find which index is being used by the > query... > > Here showing *involvedIndexes=e*, What is e? > Here *indexIsUsedInOrderBy=false*, What can be done for using an index in > the order by query? > > Thanks, > Madhu > > > On Monday, April 14, 2014 5:23:58 PM UTC+5:30, Lvc@ wrote: > >> Hi, >> if you execute it from Studio, can you open the "Raw" panel of the result >> set? It should be the JSON with the name of the index. Or otherwise >> unselect the option button "Shallow Collection" and re-execute the query. >> >> If you go into the Schema / All Indexes -> what indexes do you have? >> >> Lvc@ >> >> >> >> On 14 April 2014 13:33, madhu <[email protected]> wrote: >> >>> Hi Lvc@, >>> >>> My heap memory is default. It was taking ~1.3G. With this I tried >>> explain query. explain query also got OOME. >>> >>> Then, I increased Heap to "JAVA_OPTS=%JAVA_OPTS% -Xms512M >>> -Xmx3G-XX:MaxPermSize=512M" >>> This time I got output but very slow. Query executed in 24.14 sec. >>> Returned 300 record(s) >>> >>> The following is the output of explain query. >>> >>> *@version * >>> >>> *compositeIndexUsed * >>> >>> *involvedIndexes * >>> >>> >>> *fullySortedByIndex * >>> >>> *indexIsUsedInOrderBy * >>> >>> *current * >>> >>> * evaluated * >>> >>> *orderByElapsed * >>> >>> *elapsed * >>> >>> *resultType * >>> >>> *resultSize * >>> >>> 0 >>> >>> 1 >>> >>> [1] >>> >>> false >>> >>> false >>> >>> #9:238599 >>> >>> 226746 >>> >>> 274 >>> >>> 22814.906 >>> >>> collection >>> >>> 300 >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> Here *compositeIndexUsed=1, *but I did not create any composite index. >>> Can you explain what internally it does? >>> Is there a way to know which index is being used by the query? >>> Can you give some tips to improve orderby performance? >>> >>> Thanks, >>> Madhu >>> >>> >>> On Saturday, April 12, 2014 12:30:20 AM UTC+5:30, Lvc@ wrote: >>> >>>> Hi Madhu, >>>> How much heap do you have? Can you try doing an explain? >>>> >>>> explain select from V where STATE = 'Active' and ICON_TYPE IN >>>> [1,2,3,4,5,7] and SEV_INWIN IN [5,4,3,-1,-2] order by SEV_INWIN DESC, >>>> ICON_TYPE ASC SKIP 500 LIMIT 300 >>>> >>>> Lvc@ >>>> >>>> >>>> >>>> On 10 April 2014 17:49, madhu <[email protected]> wrote: >>>> >>>>> Hi Everyone, >>>>> >>>>> Facing an OOME with order by query execution in the following scenario. >>>>> Used orientdb version is latest 1.7-SNAPSHOT >>>>> >>>>> Total number of records in V: 238680 >>>>> Index created on SEV_INWIN property. >>>>> Index created on ICON_TYPE property. >>>>> >>>>> STATE='Active' number of records: 232492 >>>>> SEV_INWIN IN [5,4,3,-1,-2] number of records: 226746 >>>>> ICON_TYPE IN [1,2,3,4,5,7] number of records: 226746 >>>>> Number of records for the query [select count(*) from V where >>>>> ICON_TYPE IN [1,2,3,4,5,7] and SEV_INWIN IN [5,4,3,-1,-2] and >>>>> STATE='Active']: 226746 >>>>> >>>>> In this scenario, execution of the following query gives OOME. >>>>> select from V where STATE = 'Active' and ICON_TYPE IN [1,2,3,4,5,7] >>>>> and SEV_INWIN IN [5,4,3,-1,-2] order by SEV_INWIN DESC, ICON_TYPE ASC SKIP >>>>> 500 LIMIT 300 >>>>> >>>>> Can someone give suggestions to resolve this? >>>>> >>>>> Thanks, >>>>> Madhu >>>>> >>>>> -- >>>>> >>>>> --- >>>>> 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. >>>>> >>>> >>>> -- >>> >>> --- >>> 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. >>> >> >> -- > > --- > 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. > -- --- 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.
