Fix #119 (oltp_insert.lua + --auto-inc=0 fails)

Fix oltp_insert.lua when run with --auto-inc disabled. Add regression tests.
This commit is contained in:
Alexey Kopytov
2017-03-12 10:45:03 +03:00
parent 6c7c13913d
commit 89ab44d50e
10 changed files with 58 additions and 7 deletions

View File

@ -40,7 +40,8 @@ function event()
if (sysbench.opt.auto_inc) then
i = 0
else
i = sysbench.rand.unique()
-- Convert a uint32_t value to SQL INT
i = sysbench.rand.unique() - 2147483648
end
con:query(string.format("INSERT INTO %s (id, k, c, pad) VALUES " ..