Closed antipetrov closed 7 years ago
Tarantool==1.6.7-593 tarantool-python==0.5.4
I'm trying to call box.space.auth_user:auto_increment{"8", 7, 7, 7} from python script. This is what I do in python
import tarantool connection = tarantool.connect('127.0.0.1', 3303) connection.call('box.space.auth_user:auto_increment', ("8", 7, 7, 7))
And then I get the error:
[string "-- schema.lua (internal file)..."]:921: bad argument #1 to 'insert' (table expected, got string)
This is how I define my auth_user schema
box.schema.space.create('auth_user',{if_not_exists=true}) box.space.auth_user:create_index('primary', {type='TREE', if_not_exists=true, unique=true, parts={1,'NUM'}}) box.space.auth_user:create_index('login', {type='HASH', if_not_exists=true, unique=true, parts={2,'STR'}})
Am I calling it wrong?
Sorry for waiting. It should be called like this:
connection.call('box.space.auth_user:auto_increment', (("8", 7, 7, 7),))
Tarantool==1.6.7-593 tarantool-python==0.5.4
I'm trying to call box.space.auth_user:auto_increment{"8", 7, 7, 7} from python script. This is what I do in python
And then I get the error:
[string "-- schema.lua (internal file)..."]:921: bad argument #1 to 'insert' (table expected, got string)
This is how I define my auth_user schema
Am I calling it wrong?