Hello,
Can I delete multiple tuples in one shot?
-- Get minimum ID.
local min_id = box.space.dispatch_logs.index.primary:min()['id']
-- Get the minimum 1000 tuples.
result = box.space.dispatch_logs.index.primary:select(min_id, {iterator = box.index.GE, limit=1000})
Then I delete the result after getting it. How can I delete it one shot? Currently, I am doing this:
for key, value in ipairs(result) do
box.space.dispatch_logs.index.primary:delete(value['id'])
end
I think there should be a better way that my way to delete them in one shot. Is there?
Thanks a lot,
Mai