Menu

#106 Indexes on more than one field

open
nobody
None
5
2009-11-27
2009-11-27
akahanek
No

It would be very good to be possible to create "coumpound" index for more fields on more classes?

Suppose this model:

public class Person {
private Address address;
}

public class Address {
private String city;
}

The index could be created like this:

db.getClassRepresentation(Person.class).addIndexOn("someindex", new String[]{"address.city"}, true);

It is very common IMHO to filter objects not only by the queried object fields but also by the references object's fields. It is almost unpossible to query large data sets without using indexes with regards to response time.

Ales

Discussion


Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.