Hi Fabio, Sorry I didn't read your last message. You're right, indexes works only at class level. We have a proposal to support indexes at cluster level, but in the meanwhile you can create one class per cluster that extend the base "demo":
create class demo15q4 extends demo create index demo15q4.primaryid on demo15q4(primaryid) UNIQUE_HASH_INDEX create class demo15q5 extends demo create index demo15q5.primaryid on demo15q5(primaryid) UNIQUE_HASH_INDEX ... In this case both queries would work with index: SELECT FROM demo WHERE primaryid = 117596311 SELECT FROM demo15q4 WHERE primaryid = 117596311 Best Regards, Luca Garulli Founder & CEO OrientDB LTD <http://orientdb.com/> On 20 June 2016 at 10:53, Fabio Rinnone <[email protected]> wrote: > I have the same result: if I query the cluster the index is not used. > Can be a bug? > > Il 19/06/2016 20:42, Luca Garulli ha scritto: > > I think you've just create a manual index (it's up to you to populate > > it). You need an automatic index, so let's keep it strict to the SQL > syntax: > > > > > > CREATE INDEX demo.primaryid ON demo(primaryid) UNIQUE_HASH_INDEX > > > > > > > > Best Regards, > > > > Luca Garulli > > Founder & CEO > > OrientDB LTD <http://orientdb.com/> > > -- > Fabio Rinnone > Skype: fabiorinnone > Web: http://www.fabiorinnone.eu > > -- > > --- > 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.
