Tarantool CE/EE Documentation portal logo
Support

Submodule box.space

Submodule box.space

CRUD operations in Tarantool are implemented by the box.space submodule. It has the data-manipulation functions select, insert, replace, update, upsert, delete, get, put. It also has members, such as id, and whether or not a space is enabled.

Below is a list of all box.space functions and members.

Name

Use

box.schema.space.create()

Create a space

space_object:alter()

Alter a space

space_object:auto_increment()

Generate key + Insert a tuple

space_object:bsize()

Get count of bytes

space_object:count()

Get count of tuples

space_object:create_index()

Create an index

space_object:delete()

Delete a tuple

space_object:drop()

Destroy a space

space_object:format()

Declare field names and types

space_object:frommap()

Convert from map to tuple or table

space_object:get()

Select a tuple

space_object:insert()

Insert a tuple

space_object:len()

Get count of tuples

space_object:on_replace()

Create a replace trigger with a function that cannot change the tuple

space_object:before_replace()

Create a replace trigger with a function that can change the tuple

space_object:pairs()

Prepare for iterating

space_object:put()

Insert or replace a tuple

space_object:rename()

Rename a space

space_object:replace() / put()

Insert or replace a tuple

space_object:run_triggers()

Enable/disable a replace trigger

space_object:select()

Select one or more tuples

space_object:stat()

Get statistics on memory usage

space_object:truncate()

Delete all tuples

space_object:update()

Update a tuple

box_space-upgrade

Upgrade the space format and tuples

space_object:upsert()

Update a tuple

space_object extensions

Any function / method that any user wants to add

box.space.create_check_constraint()

Create a check constraint

space_object:enabled

Flag, true if space is enabled

space_object:field_count

Required number of fields

space_object.id

Numeric identifier of space

space_object.index

Container of space's indexes

./box_space/_cluster

(Metadata) List of replica sets

./box_space/_func

(Metadata) List of function tuples

./box_space/_index

(Metadata) List of indexes

./box_space/_vindex

(Metadata) List of indexes accessible for the current user

./box_space/_priv

(Metadata) List of privileges

./box_space/_vpriv

(Metadata) List of privileges accessible for the current user

./box_space/_schema

(Metadata) List of schemas

./box_space/_sequence

(Metadata) List of sequences

./box_space/_sequence_data

(Metadata) List of sequences

./box_space/_space

(Metadata) List of spaces

./box_space/_vspace

(Metadata) List of spaces accessible for the current user

./box_space/_space_sequence

(Metadata) List of connections between spaces and sequences

./box_space/_vspace_sequence

(Metadata) List of connections between spaces and sequences accessible for the current user

./box_space/_user

(Metadata) List of users

./box_space/_vuser

(Metadata) List of users accessible for the current user

./box_space/_ck_constraint

(Metadata) List of check constraints

./box_space/_collation

(Metadata) List of collations

./box_space/_vcollation

(Metadata) List of collations accessible for the current user

System space views

(Metadata) Spaces whose names begin with v

./box_space/_session_settings

(Metadata) List of settings affecting behavior of the current session

To see examples, visit the how-to guide on CRUD operations.