Details
-
Bug
-
Resolution: Known Error
-
Major
-
None
-
7.0.0
-
Untriaged
-
1
-
Unknown
Description
Multi-collection indexes have scoreUID+collectionUID prefixed to the key - the _id stored within the index. While docID searches work ok, sorting still happens to use the prefixed key - which could cause results to be in an unexpected order if the query were to span multiple collections.
Hits will be grouped and sorted by collections and within those collections, they will be sorted correctly.
For example ..
Document | Bucket.Scope.Collection |
---|---|
doc1 | bucket.scope.coll2 |
doc2 | bucket.scope.coll1 |
doc3 | bucket.scope.coll2 |
doc4 | bucket.scope.coll1 |
If all the documents above qualify some search criteria which orders it by "_id", the hits will be ordered this way ..
1. doc2 |
2. doc4 |
3. doc1 |
4. doc3 |