crud icon indicating copy to clipboard operation
crud copied to clipboard

Don't consider multikey/functional indexes in query planner

Open olegrok opened this issue 5 years ago • 3 comments

Seems it's quite complex task - multikey index support for several reasons:

  • Tarantool doesn't provide user-friendly ways to merge tuples from multikey indexes (see https://github.com/tarantool/tarantool/issues/5270)
  • Multikey index could return single tuple several times that could confuse users and we don't have "distinct option"
  • Usage of multikey indexes requires FFI magic with Tarantool tree iterator - and it's different in different Tarantool versions
  • May be it will be great to support "ALL IN" or "ANY IN" operators for multikey indexes (e.g. I have indexed array [1, 2, 3]. If I specify {"> ANY", 'array', 2} - it's true, because "3 > 2" matches, but {"> ALL", 'array', 2} because "2 > 2" - false and "1 > 2" - false)

olegrok avatar Sep 24 '20 06:09 olegrok

Can you describe it as a problem in crud's user visible behaviour? It would help me to prioritize it right.

Totktonada avatar Dec 23 '21 19:12 Totktonada

Currently you don't have adequate way how to merge multikey indexes. Merger doesn't support it. I guess user will see unclear error in such case.

It would help me to prioritize it right.

I guess it's not priority task since there are no users who has faced this issue.

olegrok avatar Dec 23 '21 19:12 olegrok

Thanks! I'll consider it as 'good to implement in a spare time' (part of our backlog without certain deadlines).

If we'll plan to systematically work on proper multikey index support in tuple-keydef, tuple-merger and crud, it'll gain priority.

Totktonada avatar Dec 23 '21 19:12 Totktonada