Tarantool CE/EE Documentation portal logo
Support
Updated at July 17, 2026   02:08 PM

space_object:truncate()

space_object method truncate()

Deletes all tuples. The method is performed in background and doesn't block consequent requests.

Parameters:

Complexity factors: Index size, Index type, Number of tuples accessed.

Returns

nil

The truncate method can only be called by the user who created the space, or from within a setuid function created by the user who created the space. Read more about [setuid]{.title-ref} functions in the reference for /reference/reference_lua/box_schema/func_create.

Example:

tarantool> box.space.tester:truncate()---...tarantool> box.space.tester:len()---- 0...