We have a very large index where we match content by some standard fields.
Let’s say we have the following index:
CREATE INDEX ON `bucket`(`large_set`, `medium_set`, `small_set`) WHERE `x`=1
Would it be more efficient to refactor the index to be:
CREATE INDEX ON `bucket`(`small_set`, `medium_set`, `large_set`) WHERE `x`=1
Assuming that all of our queries filter on all of the data in the ON clause?
Our current problem is index counts timing out:
SELECT count(1) FROM `bucket` WHERE `x`=1 AND `large_set` = "L" AND `medium_set` = "M" AND `small_set` = "L"
This is currently giving us problems (timeouts) with Couchbase 4.5.1…
Thanks - H