Top.Mail.Ru
space_object:insert() | Tarantool
Submodule box.space / space_object:insert()
Tarantool
Check out the new release 2.8
Submodule box.space / space_object:insert()

space_object:insert()

space_object:insert()

object space_object
space_object:insert(tuple)

Insert a tuple into a space.

Parameters:
Return:

the inserted tuple

Rtype:

tuple

Possible errors: ER_TUPLE_FOUND if a tuple with the same unique-key value already exists.

Example:

tarantool> box.space.tester:insert{5000,'tuple number five thousand'}
---
- [5000, 'tuple number five thousand']
...

For more usage scenarios and typical errors see Example: using data operations further in this section.