Details
-
Improvement
-
Resolution: Fixed
-
Major
-
6.5.1
-
CX Sprint 219, CX Sprint 220, CX Sprint 221, CX Sprint 222, CX Sprint 223, CX Sprint 248, CX Sprint 249, CX Sprint 250, CX Sprint 251, CX Sprint 252, CX Sprint 253, CX Sprint 254, CX Sprint 255, CX Sprint 256, CX Sprint 257, CX Sprint 258, CX Sprint 259
Description
Composite secondary index is currently not chosen by the query optimizer if the predicate does not include all indexed fields.
E.g.
CREATE DATASET breweries ON `beer-sample` WHERE `type` = "brewery";
|
CREATE INDEX idx_country_state ON breweries(country:string, state:string);
|
Query:
SELECT *
|
FROM breweries
|
WHERE country = 'United States';
|
The above secondary index is currently not used because the WHERE clause does not include predicate on the 'state' field.