I have two questions about indices and their using in orient-db:
I have an embedded map inside a class (called AttributeValue) that is used
to store translations as key/value pair. The values property looks like
this:
{
"b9909ab4-3fcf-4750-9dda-3a242eaee4e7": {
"@type": "d",
"@version": 0,
"@class": "Translation",
"value": "Identifier"
},
"f947c86e-a227-4307-a30b-80bc642bdb9e": {
"@type": "d",
"@version": 0,
"@class": "Translation",
"value": "Bezeichnung"
}
}
the key is a uuid of a language, the value-document contains the value of
the translation.
It is possible to create a index for the translation values that sql
statement like
select * from AttributeValue where values[b9909ab4-3fcf-4750-9dda-
3a242eaee4e7]['value'] = 'Identifier'
will use this index? How would the statement or java api call for creating
such an index look like. I just found some information about creating
indices for keys of maps, not about values (especially complex ones).
My second question is about index using in sub-queries. When i run
something like (indexedProperty has a UNIQUE index on this class)
explain select * from MyClass where indexedProperty = 'Test'
i get following result
{
"result": [
{
[...]
"compositeIndexUsed": 1,
"involvedIndexes": [
1
],
[....]
}
],
"notification": "Query executed in 0.026 sec. Returned 1 record(s)"
}
That's what i expected. But if i do something like
explain select from (traverse in('edge') from (select from Characteristic
where CID = 'Test'))
the result shows no involved indices. Is this just a "display bug" because
Indices used in sub-queries are not displayed or is the result right and if
i do an query that should use an index as an subquery the index isn't used.
thanks for your help.
best regards chris
--
---
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.