Skip to content
Snippets Groups Projects
Commit 78102868 authored by Roman Tsisyk's avatar Roman Tsisyk Committed by Konstantin Osipov
Browse files

Don't store offsets for sequential multi-parts keys

Optimize tuple format for cases when all keys are sequential and
start from the first field:

    box.schema.space.create('memtx')
    box.space.memtx:create_index('sequential0', { parts =
        { 1, 'unsigned' }})
    box.space.memtx:create_index('sequential1', { parts =
        { 1, 'unsigned', 2, 'unsigned' }})
    box.space.memtx:create_index('sequential2', { parts =
        { 1, 'unsigned', 2, 'unsigned', 3, 'unsigned', 4, 'unsigned' }})
    box.space.memtx:create_index('random1', { parts =
        { 3, 'unsigned' } })

In the example above only field 3 is now indexed by offset (was 2, 3, 4).

+ Improve error message in field_type_create()

Closes #2046
parent 5472def1
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment