desc: sindex api (#602)
tests:

  - cd: r.db('test').table_create('sindex_api')
    def: tbl = r.table('sindex_api')

  - def: rows = [{'id':0, 'a':0, 'b':0, 'c':0, 'm':[1,2,3]},
                 {'id':1, 'a':0, 'b':0, 'c':0, 'm':[4,5,6]},
                 {'id':2, 'a':0, 'b':0, 'c':1, 'm':7},
                 {'id':3, 'a':0, 'b':1, 'c':1, 'm':[10,11,12]},
                 {'id':4, 'a':4, 'b':4, 'c':4, 'm':[14,15,16]}]

  - cd: tbl.insert([{'id':0, 'a':0, 'b':0, 'c':0, 'm':[1,2,3]},
                    {'id':1, 'a':0, 'b':0, 'c':0, 'm':[4,5,6]},
                    {'id':2, 'a':0, 'b':0, 'c':1, 'm':7},
                    {'id':3, 'a':0, 'b':1, 'c':1, 'm':[10,11,12]}])
    ot: ({'deleted':0,'inserted':4,'skipped':0,'errors':0,'replaced':0,'unchanged':0})

  - rb: tbl.index_create('ai') {|row| row[:a]}
    py: tbl.index_create('ai', r.row['a'])
    js: tbl.indexCreate('ai', r.row('a'))
    ot: ({'created':1})
  - rb: tbl.index_create('ai') {|row| row[:a]}
    py: tbl.index_create('ai', r.row['a'])
    js: tbl.indexCreate('ai', r.row('a'))
    ot: 'err("RqlRuntimeError", "Index `ai` already exists.", [])'
  - rb: tbl.index_create('bi') {|row| row[:b]}
    py: tbl.index_create('bi', r.row['b'])
    js: tbl.indexCreate('bi', r.row('b'))
    ot: ({'created':1})
  - rb: tbl.index_create('ci') {|row| row[:c]}
    py: tbl.index_create('ci', r.row['c'])
    js: tbl.indexCreate('ci', r.row('c'))
    ot: ({'created':1})
  - rb: tbl.index_create('idi') {|row| row[:id]}
    py: tbl.index_create('idi', r.row['id'])
    js: tbl.indexCreate('idi', r.row('id'))
    ot: ({'created':1})
  - rb: tbl.index_create('kdi') {|row| [row[:id]]}
    py: tbl.index_create('kdi', [r.row['id']])
    js: tbl.indexCreate('kdi', [r.row('id')])
    ot: ({'created':1})
  - rb: tbl.index_create('mi', :multi => True) {|row| row[:m]}
    py: tbl.index_create('mi', r.row['m'], multi=True)
    js: tbl.indexCreate('mi', r.row('m'), {"multi":true})
    ot: ({'created':1})
  - rb: tbl.index_create('brokeni') {|row| row[:broken]}
    py: tbl.index_create('brokeni', r.row['broken'])
    js: tbl.indexCreate('brokeni', r.row('broken'))
    ot: ({'created':1})

  - cd: tbl.get(true)
    py: tbl.get(True)
    # No error

  - cd: tbl.get([])
    ot: (null)
  - cd: tbl.get(-1)
    ot: (null)
  - rb: tbl.get(1)[:id]
    py: tbl.get(1)['id']
    js: tbl.get(1)('id')
    ot: 1
  - rb: tbl.get(1).typeof
    py: tbl.get(1).type_of()
    js: tbl.get(1).typeOf()
    ot: ('SELECTION<OBJECT>')
  - rb: tbl.get(1).update{nil}
    py: tbl.get(1).update(lambda x:None)
    js: tbl.get(1).update(function(x) { return null;})
    ot: ({'replaced':0,'skipped':0,'deleted':0,'unchanged':1,'errors':0,'inserted':0})
  - rb: tbl.get(1, :ai)
    cd: tbl.get(1, 'ai')
    ot:
      rb: 'err("RqlCompileError", "Expected 2 argument(s) but found 3.", [])'
      py: err("TypeError", 'get() takes exactly 2 arguments (3 given)')
      js: err("RqlDriverError", 'Expected 1 argument(s) but found 2.')

  - rb: tbl.get_all(true, :index => :id)
    py: tbl.get_all(True, index='id')
    js: tbl.getAll(true, {index:'id'})
    # No error

  - rb: tbl.get_all(-1, :index => :id)
    py: tbl.get_all(-1, index='id')
    js: tbl.getAll(-1, {index:'id'})
    ot: []
  - rb: tbl.get_all(-1)
    py: tbl.get_all(-1)
    js: tbl.getAll(-1)
    ot: []
  - rb: tbl.get_all([-1])
    py: tbl.get_all([-1])
    js: tbl.getAll([-1])
    ot: []
  - rb: tbl.get_all(1, :index => :id)[0][:id]
    py: tbl.get_all(1, index='id')[0]['id']
    js: tbl.getAll(1, {index:'id'}).nth(0)('id')
    ot: 1
  - rb: tbl.get_all(1)[0][:id]
    py: tbl.get_all(1)[0]['id']
    js: tbl.getAll(1).nth(0)('id')
    ot: 1
  - rb: tbl.get_all(1,2,3, :index => :id).map{|x| x[:id]}.coerce_to("ARRAY")
    py: tbl.get_all(1,2,3, index='id').map(lambda x:x["id"]).coerce_to("ARRAY")
    js: tbl.getAll(1,2,3, {index:'id'}).map(function (x) { return x("id"); }).coerce_to("ARRAY")
    ot: [1,2,3]
  - rb: tbl.get_all(1,2,3).map{|x| x[:id]}.coerce_to("ARRAY")
    py: tbl.get_all(1,2,3).map(lambda x:x["id"]).coerce_to("ARRAY")
    js: tbl.getAll(1,2,3).map(function (x) { return x("id"); }).coerce_to("ARRAY")
    ot: [1,2,3]
  - rb: tbl.get_all(1, :index => :id).typeof
    py: tbl.get_all(1, index='id').type_of()
    js: tbl.getAll(1, {index:'id'}).typeOf()
    ot: ('SELECTION<ARRAY>')
  - rb: tbl.get_all(1).typeof
    py: tbl.get_all(1).type_of()
    js: tbl.getAll(1).typeOf()
    ot: ('SELECTION<ARRAY>')
  - rb: tbl.get_all(1, :index => :id).update{nil}
    py: tbl.get_all(1, index='id').update(lambda x:None)
    js: tbl.getAll(1, {index:'id'}).update(function(x) { return null; })
    ot: ({'replaced':0,'skipped':0,'deleted':0,'unchanged':1,'errors':0,'inserted':0})
  - rb: tbl.get_all(1).update{nil}
    py: tbl.get_all(1).update(lambda x:None)
    js: tbl.getAll(1).update(function(x) { return null; })
    ot: ({'replaced':0,'skipped':0,'deleted':0,'unchanged':1,'errors':0,'inserted':0})
  - rb: tbl.get_all(1,2,3, :index => :id).update{nil}
    py: tbl.get_all(1,2,3, index='id').update(lambda x:None)
    js: tbl.getAll(1,2,3, {index:'id'}).update(function(x) { return null; })
    ot: ({'replaced':0,'skipped':0,'deleted':0,'unchanged':3,'errors':0,'inserted':0})
  - rb: tbl.get_all(1,2,3).update{nil}
    py: tbl.get_all(1,2,3).update(lambda x:None)
    js: tbl.getAll(1,2,3).update(function(x) { return null; })
    ot: ({'replaced':0,'skipped':0,'deleted':0,'unchanged':3,'errors':0,'inserted':0})

  - rb: tbl.get_all(0, :index => :fake)
    py: tbl.get_all(0, index='fake')
    js: tbl.getAll(0, {index:'fake'})
    ot: 'err("RqlRuntimeError", "Index `fake` was not found.", [])'
  - rb: tbl.get_all(0, :index => false)
    py: tbl.get_all(0, index=False)
    js: tbl.getAll(0, {index:false})
    ot: 'err("RqlRuntimeError", "Expected type STRING but found BOOL.", [])'

  - rb: tbl.get_all(true, :index => :id)
    py: tbl.get_all(True, index='id')
    js: tbl.getAll(true, {index:'id'})
    # No error

  - rb: tbl.get_all([], :index => :id)
    py: tbl.get_all([], index='id')
    js: tbl.getAll([], {index:'id'})
    ot: ([])
  - rb: tbl.get_all(true, :index => :idi)
    py: tbl.get_all(True, index='idi')
    js: tbl.getAll(true, {index:'idi'})
    # No error

  - rb: tbl.get_all([], :index => :idi)
    py: tbl.get_all([], index='idi')
    js: tbl.getAll([], {index:'idi'})
    ot: []

  - rb: tbl.get_all(1, :index => :id)[0][:id]
    py: tbl.get_all(1, index='id')[0]['id']
    js: tbl.getAll(1, {index:'id'}).nth(0)('id')
    ot: 1
  - rb: tbl.get_all(1, :index => :idi)[0][:id]
    py: tbl.get_all(1, index='idi')[0]['id']
    js: tbl.getAll(1, {index:'idi'}).nth(0)('id')
    ot: 1
  - rb: tbl.get_all(1, :index => :ai)
    py: tbl.get_all(1, index='ai')
    js: tbl.getAll(1, {index:'ai'})
    ot: []
  - rb: tbl.get_all(1, :index => :bi).orderby(:id).map{|x| x[:id]}
    py: tbl.get_all(1, index='bi').order_by('id').map(lambda x:x['id'])
    js: tbl.getAll(1, {index:'bi'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [3]
  - rb: tbl.get_all(1, :index => :bi).orderby(:index => :id).map{|x| x[:id]}
    py: tbl.get_all(1, index='bi').order_by(index='id').map(lambda x:x['id'])
    js: tbl.getAll(1, {index:'bi'}).orderBy({index:'id'}).map(function(x) { return x('id'); })
    ot: err('RqlRuntimeError', 'Indexed order_by can only be performed on a TABLE.', [0])
  - rb: tbl.get_all(1, :index => :bi).between(1, 1, :index => :id).map{|x| x[:id]}
    py: tbl.get_all(1, index='bi').between(1, 1, index='id').map(lambda x:x['id'])
    js: tbl.getAll(1, {index:'bi'}).between(1, 1, {index:'id'}).map(function(x) { return x('id'); })
    ot: err('RqlRuntimeError', 'Expected type TABLE but found SELECTION.', [0])
  - rb: tbl.get_all(1, :index => :ci).orderby(:id).map{|x| x[:id]}
    py: tbl.get_all(1, index='ci').order_by('id').map(lambda x:x['id'])
    js: tbl.getAll(1, {index:'ci'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [2, 3]
  - rb: tbl.get_all(1, :index => :ci).typeof
    py: tbl.get_all(1, index='ci').type_of()
    js: tbl.getAll(1, {index:'ci'}).typeOf()
    ot: ('SELECTION<STREAM>')
  - rb: tbl.get_all(1, :index => :ci).update{nil}
    py: tbl.get_all(1, index='ci').update(lambda x:None)
    js: tbl.getAll(1, {index:'ci'}).update(function(x) { return null; })
    ot: ({'replaced':0,'skipped':0,'deleted':0,'unchanged':2,'errors':0,'inserted':0})
  - rb: tbl.get_all(1, :index => :brokeni)
    py: tbl.get_all(1, index='brokeni')
    js: tbl.getAll(1, {index:'brokeni'})
    ot: []

  - rb: tbl.get_all(1, :index => :mi)
    py: tbl.get_all(1, index='mi')
    js: tbl.getAll(1, {index:'mi'})
    ot: ([rows[0]])

  - rb: tbl.get_all(2, :index => :mi)
    py: tbl.get_all(2, index='mi')
    js: tbl.getAll(2, {index:'mi'})
    ot: ([rows[0]])

  - rb: tbl.get_all(5, :index => :mi)
    py: tbl.get_all(5, index='mi')
    js: tbl.getAll(5, {index:'mi'})
    ot: ([rows[1]])

  - rb: tbl.get_all(7, :index => :mi)
    py: tbl.get_all(7, index='mi')
    js: tbl.getAll(7, {index:'mi'})
    ot: ([rows[2]])

  - rb: tbl.eq_join(:id, tbl, :index => :fake)
    py: tbl.eq_join('id', tbl, index='fake')
    js: tbl.eqJoin('id', tbl, {index:'fake'})
    ot: 'err("RqlRuntimeError", "Index `fake` was not found.", [])'
  - rb: tbl.eq_join(:id, tbl, :index => false)
    py: tbl.eq_join('id', tbl, index=False)
    js: tbl.eqJoin('id', tbl, {index:false})
    ot: 'err("RqlRuntimeError", "Expected type STRING but found BOOL.", [])'

  - rb: tbl.filter({:id => 1}).eq_join(:id, tbl, :index => :mi)
    py: tbl.filter({'id':1}).eq_join('id', tbl, index='mi')
    js: tbl.filter({id:1}).eqJoin('id', tbl, {index:'mi'})
    ot: ([{'left':rows[1],'right':rows[0]}])

  - rb: tbl.filter({:id => 0}).eq_join(:id, tbl)
    py: tbl.filter({'id':0}).eq_join('id', tbl)
    js: tbl.filter({'id':0}).eqJoin('id', tbl)
    ot: ([{'left':rows[0],'right':rows[0]}])

  - rb: tbl.filter({:id => 0}).eq_join(lambda{|x| x[:id]}, tbl)
    py: "tbl.filter({'id':0}).eq_join(lambda x: x['id'], tbl)"
    js: tbl.filter({'id':0}).eqJoin(function (x) { return x('id'); }, tbl)
    ot: ([{'left':rows[0],'right':rows[0]}])

  - rb: tbl.filter({:id => 0}).eq_join(:id, tbl, :index => :id)
    py: tbl.filter({'id':0}).eq_join('id', tbl, index='id')
    js: tbl.filter({'id':0}).eqJoin('id', tbl, {index:'id'})
    ot: ([{'left':rows[0],'right':rows[0]}])

  - rb: tbl.filter({:id => 0}).eq_join(lambda {|x| x[:id]}, tbl, :index => :id)
    py: "tbl.filter({'id':0}).eq_join(lambda x: x['id'], tbl, index='id')"
    js: tbl.filter({'id':0}).eqJoin(function (x) { return x('id'); }, tbl, {index:'id'})
    ot: ([{'left':rows[0],'right':rows[0]}])

  - rb: tbl.filter({:id => 0}).eq_join(:id, tbl, :index => :idi)
    py: tbl.filter({'id':0}).eq_join('id', tbl, index='idi')
    js: tbl.filter({'id':0}).eqJoin('id', tbl, {index:'idi'})
    ot: ([{'left':rows[0],'right':rows[0]}])

  - rb: tbl.filter({:id => 0}).eq_join(lambda {|x| x[:id]}, tbl, :index => :idi)
    py: "tbl.filter({'id':0}).eq_join(lambda x: x['id'], tbl, index='idi')"
    js: tbl.filter({'id':0}).eqJoin(function (x) { return x('id'); }, tbl, {index:'idi'})
    ot: ([{'left':rows[0],'right':rows[0]}])

  - rb: tbl.filter({:id => 0}).eq_join(:id, tbl, :index => :ai).orderby(:right)
    py: tbl.filter({'id':0}).eq_join('id', tbl, index='ai').order_by('right')
    js: tbl.filter({'id':0}).eqJoin('id', tbl, {index:'ai'}).orderBy('right')
    ot: ([{'right':rows[0],'left':rows[0]},
          {'right':rows[1],'left':rows[0]},
          {'right':rows[2],'left':rows[0]},
          {'right':rows[3],'left':rows[0]}])
  - rb: tbl.filter({:id => 0}).eq_join(:id, tbl, :index => :bi).orderby(:right)
    py: tbl.filter({'id':0}).eq_join('id', tbl, index='bi').order_by('right')
    js: tbl.filter({'id':0}).eqJoin('id', tbl, {index:'bi'}).orderBy('right')
    ot: ([{'right':rows[0],'left':rows[0]},
          {'right':rows[1],'left':rows[0]},
          {'right':rows[2],'left':rows[0]}])
  - rb: tbl.filter({:id => 0}).eq_join(:id, tbl, :index => :ci).orderby(:right)
    py: tbl.filter({'id':0}).eq_join('id', tbl, index='ci').order_by('right')
    js: tbl.filter({'id':0}).eqJoin('id', tbl, {index:'ci'}).orderBy('right')
    ot: ([{'right':rows[0],'left':rows[0]},
          {'right':rows[1],'left':rows[0]}])
  - rb: tbl.filter({:id => 0}).eq_join(:id, tbl, :index => :brokeni)
    py: tbl.filter({'id':0}).eq_join('id', tbl, index='brokeni')
    js: tbl.filter({'id':0}).eqJoin('id', tbl, {index:'brokeni'})
    ot: []

  - rb: tbl.eq_join(:c, tbl, :index => :bi).orderby(:right, :left)
    py: tbl.eq_join('c', tbl, index='bi').order_by('right', 'left')
    js: tbl.eqJoin('c', tbl, {index:'bi'}).orderBy('right', 'left')
    ot: ([{'left':rows[0],'right':rows[0]},
          {'left':rows[1],'right':rows[0]},
          {'left':rows[0],'right':rows[1]},
          {'left':rows[1],'right':rows[1]},
          {'left':rows[0],'right':rows[2]},
          {'left':rows[1],'right':rows[2]},
          {'left':rows[2],'right':rows[3]},
          {'left':rows[3],'right':rows[3]}])

  - cd: tbl.index_create('id')
    ot: 'err("RqlRuntimeError", "Index name conflict: `id` is the name of the primary key.", [])'

  - cd: tbl.index_create('c')
    ot: ({'created':1})
  - cd: tbl.index_create('broken')
    ot: ({'created':1})

  - rb: tbl.get_all(1, :index => 'c').orderby(:id).map{|x| x[:id]}
    py: tbl.get_all(1, index='c').order_by('id').map(lambda x:x['id'])
    js: tbl.getAll(1, {index:'c'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [2, 3]
  - rb: tbl.get_all(1, :index => 'broken').orderby(:broken).map{|x| x[:id]}
    py: tbl.get_all(1, index='broken').order_by('broken').map(lambda x:x['id'])
    js: tbl.getAll(1, {index:'broken'}).orderBy('broken').map(function(x) { return x('id'); })
    ot: []

  - rb: tbl.index_create('nil') {nil}
    py: tbl.index_create('nil', lambda x:None)
    js: tbl.indexCreate('nil', function(x) { return null; })
    ot: ({'created':1})
  - rb: tbl.get_all(nil, :index => :nil)
    py: tbl.get_all(None, index='nil')
    js: tbl.getAll(null, {index:'nil'})
    ot:
      py: 'err("RqlRuntimeError", "Secondary keys must be a number, string, bool, or array (got nu""ll of type NULL).", [])'
      rb: 'err("RqlRuntimeError", "Secondary keys must be a number, string, bool, or array (got nu""ll of type NULL).", [])'
      js: 'err("RqlRuntimeError", "Secondary keys must be a number, string, bool, or array (got null of type NULL).", [])'

  - rb: tbl.insert({:id => 4, :a => 4, :b => 4, :c => 4, :m => [14,15,16]})
    cd: tbl.insert({'id':4, 'a':4, 'b':4, 'c':4, 'm':[14,15,16]})
    ot: ({'deleted':0,'inserted':1,'skipped':0,'errors':0,'replaced':0,'unchanged':0})

  - def:

  # We test to make sure that the other indexes were updated after the insert.
  - rb: tbl.eq_join(:id, tbl, :index => :c).orderby(:left, :right).coerce_to("ARRAY")
    py: tbl.eq_join('id', tbl, index='c').order_by('left', 'right').coerce_to("ARRAY")
    js: tbl.eqJoin('id', tbl, {index:'c'}).orderBy('left', 'right').coerceTo("ARRAY")
    ot: ([{'right':rows[0],'left':rows[0]},
          {'right':rows[1],'left':rows[0]},
          {'right':rows[2],'left':rows[1]},
          {'right':rows[3],'left':rows[1]},
          {'right':rows[4],'left':rows[4]}])

  - rb: tbl.eq_join(:id, tbl, :index => :ci).orderby(:left, :right)
    py: tbl.eq_join('id', tbl, index='ci').order_by('left', 'right')
    js: tbl.eqJoin('id', tbl, {index:'ci'}).orderBy('left', 'right')
    ot: ([{'right':rows[0],'left':rows[0]},
          {'right':rows[1],'left':rows[0]},
          {'right':rows[2],'left':rows[1]},
          {'right':rows[3],'left':rows[1]},
          {'right':rows[4],'left':rows[4]}])

  - rb: tbl.between(nil, nil).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, None).order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, null).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(nil, nil).orderby(:index => :id).map{|x| x[:id]}
    py: tbl.between(None, None).order_by(index='id').map(lambda x:x['id'])
    js: tbl.between(null, null).orderBy({index:'id'}).map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(nil, nil).between(nil, nil).map{|x| x[:id]}
    py: tbl.between(None, None).between(None, None).map(lambda x:x['id'])
    js: tbl.between(null, null).between(null, null).map(function(x) { return x('id'); })
    ot: err('RqlRuntimeError', 'Cannot chain multiple betweens to the same table.', [0])
  - rb: tbl.between(0, nil).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, None).order_by('id').map(lambda x:x['id'])
    js: tbl.between(0, null).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(nil, 4).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, 4).order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, 4).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3]
  - rb: tbl.between(0, 4).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, 4).order_by('id').map(lambda x:x['id'])
    js: tbl.between(0, 4).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3]
  - rb: tbl.between(-1, 5).orderby(:id).map{|x| x[:id]}
    py: tbl.between(-1, 5).order_by('id').map(lambda x:x['id'])
    js: tbl.between(-1, 5).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(5, 5).orderby(:id).map{|x| x[:id]}
    py: tbl.between(5, 5).order_by('id').map(lambda x:x['id'])
    js: tbl.between(5, 5).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(5, nil).orderby(:id).map{|x| x[:id]}
    py: tbl.between(5, None).order_by('id').map(lambda x:x['id'])
    js: tbl.between(5, null).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(-1, -1).orderby(:id).map{|x| x[:id]}
    py: tbl.between(-1, -1).order_by('id').map(lambda x:x['id'])
    js: tbl.between(-1, -1).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(nil, -1).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, -1).order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, -1).orderBy('id').map(function(x) { return x('id'); })
    ot: []

  - rb: tbl.between(nil, nil, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, None, right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, null, {'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(0, nil, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, None, right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(0, null, {'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(nil, 4, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, 4, right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, 4, {'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(0, 4, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, 4, right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(0, 4, {'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(-1, 5, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(-1, 5, right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(-1, 5, {'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(5, 5, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(5, 5, right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(5, 5, {'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(5, nil, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(5, None, right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(5, null, {'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(-1, -1, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(-1, -1, right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(-1, -1, {'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(nil, -1, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, -1, right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, -1, {'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []

  - rb: tbl.between(nil, nil, :index => :id).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, None, index='id').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, null, {index:'id'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(0, nil, :index => :id).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, None, index='id').order_by('id').map(lambda x:x['id'])
    js: tbl.between(0, null, {index:'id'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(nil, 4, :index => :id).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, 4, index='id').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, 4, {index:'id'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3]
  - rb: tbl.between(0, 4, :index => :id).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, 4, index='id').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, 4, {index:'id'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3]
  - rb: tbl.between(-1, 5, :index => :id).orderby(:id).map{|x| x[:id]}
    py: tbl.between(-1, 5, index='id').order_by('id').map(lambda x:x['id'])
    js: tbl.between(-1, 5, {index:'id'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(5, 5, :index => :id).orderby(:id).map{|x| x[:id]}
    py: tbl.between(5, 5, index='id').order_by('id').map(lambda x:x['id'])
    js: tbl.between(5, 5, {index:'id'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(5, nil, :index => :id).orderby(:id).map{|x| x[:id]}
    py: tbl.between(5, None, index='id').order_by('id').map(lambda x:x['id'])
    js: tbl.between(5, null, {index:'id'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(-1, -1, :index => :id).orderby(:id).map{|x| x[:id]}
    py: tbl.between(-1, -1, index='id').order_by('id').map(lambda x:x['id'])
    js: tbl.between(-1, -1, {index:'id'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(nil, -1, :index => :id).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, -1, index='id').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, -1, {index:'id'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []

  - rb: tbl.between(nil, nil, :index => :id, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, None, index='id', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, null, {'index':'id', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(0, nil, :index => :id, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, None, index='id', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(0, null, {'index':'id', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(nil, 4, :index => :id, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, 4, index='id', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, 4, {'index':'id', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(0, 4, :index => :id, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, 4, index='id', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, 4, {'index':'id', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(-1, 5, :index => :id, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(-1, 5, index='id', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(-1, 5, {'index':'id', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(5, 5, :index => :id, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(5, 5, index='id', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(5, 5, {'index':'id', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(5, nil, :index => :id, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(5, None, index='id', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(5, null, {'index':'id', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(-1, -1, :index => :id, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(-1, -1, index='id', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(-1, -1, {'index':'id', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(nil, -1, :index => :id, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, -1, index='id', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, -1, {'index':'id', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []

  - rb: tbl.between(nil, nil, :index => :idi).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, None, index='idi').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, null, {index:'idi'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(0, nil, :index => :idi).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, None, index='idi').order_by('id').map(lambda x:x['id'])
    js: tbl.between(0, null, {index:'idi'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(nil, 4, :index => :idi).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, 4, index='idi').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, 4, {index:'idi'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3]
  - rb: tbl.between(0, 4, :index => :idi).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, 4, index='idi').order_by('id').map(lambda x:x['id'])
    js: tbl.between(0, 4, {index:'idi'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3]
  - rb: tbl.between(-1, 5, :index => :idi).orderby(:id).map{|x| x[:id]}
    py: tbl.between(-1, 5, index='idi').order_by('id').map(lambda x:x['id'])
    js: tbl.between(-1, 5, {index:'idi'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(5, 5, :index => :idi).orderby(:id).map{|x| x[:id]}
    py: tbl.between(5, 5, index='idi').order_by('id').map(lambda x:x['id'])
    js: tbl.between(5, 5 , {index:'idi'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(5, nil, :index => :idi).orderby(:id).map{|x| x[:id]}
    py: tbl.between(5, None, index='idi').order_by('id').map(lambda x:x['id'])
    js: tbl.between(5, null, {index:'idi'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(-1, -1, :index => :idi).orderby(:id).map{|x| x[:id]}
    py: tbl.between(-1, -1, index='idi').order_by('id').map(lambda x:x['id'])
    js: tbl.between(-1, -1, {index:'idi'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(nil, -1, :index => :idi).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, -1, index='idi').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, -1, {index:'idi'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []

  - rb: tbl.between(nil, nil, :index => :idi, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, None, index='idi', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, null, {'index':'idi', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(0, nil, :index => :idi, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, None, index='idi', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(0, null, {'index':'idi', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(nil, 4, :index => :idi, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, 4, index='idi', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, 4, {'index':'idi', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(0, 4, :index => :idi, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, 4, index='idi', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(0, 4, {'index':'idi', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(-1, 5, :index => :idi, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(-1, 5, index='idi', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(-1, 5, {'index':'idi', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(5, 5, :index => :idi, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(5, 5, index='idi', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(5, 5 , {'index':'idi', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(5, nil, :index => :idi, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(5, None, index='idi', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(5, null, {'index':'idi', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(-1, -1, :index => :idi, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(-1, -1, index='idi', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(-1, -1, {'index':'idi', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(nil, -1, :index => :idi, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, -1, index='idi', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, -1, {'index':'idi', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []

  - rb: tbl.between(nil, nil, :index => :ai).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, None, index='ai').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, null, {index:'ai'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(0, nil, :index => :ai).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, None, index='ai').order_by('id').map(lambda x:x['id'])
    js: tbl.between(0, null, {index:'ai'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(nil, 4, :index => :ai).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, 4, index='ai').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, 4, {index:'ai'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3]
  - rb: tbl.between(0, 4, :index => :ai).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, 4, index='ai').order_by('id').map(lambda x:x['id'])
    js: tbl.between(0, 4, {index:'ai'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3]
  - rb: tbl.between(0, 5, :index => :ai).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, 5, index='ai').order_by('id').map(lambda x:x['id'])
    js: tbl.between(0, 5, {index:'ai'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]

  - rb: tbl.between(nil, nil, :index => :ai, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, None, index='ai', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, null, {'index':'ai', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(0, nil, :index => :ai, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, None, index='ai', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(0, null, {'index':'ai', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(nil, 4, :index => :ai, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, 4, index='ai', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, 4, {'index':'ai', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(0, 4, :index => :ai, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, 4, index='ai', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(0, 4, {'index':'ai', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(0, 5, :index => :ai, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, 5, index='ai', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(0, 5, {'index':'ai', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]

  - rb: tbl.between(0, 3, :index => :ai).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, 3, index='ai').order_by('id').map(lambda x:x['id'])
    js: tbl.between(0, 3, {index:'ai'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3]
  - rb: tbl.between(0, 1, :index => :ai).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, 1, index='ai').order_by('id').map(lambda x:x['id'])
    js: tbl.between(0, 1, {index:'ai'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3]
  - rb: tbl.between(0, 0, :index => :ai).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, 0, index='ai').order_by('id').map(lambda x:x['id'])
    js: tbl.between(0, 0, {index:'ai'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(-1, 2, :index => :ai).orderby(:id).map{|x| x[:id]}
    py: tbl.between(-1, 2, index='ai').order_by('id').map(lambda x:x['id'])
    js: tbl.between(-1, 2, {index:'ai'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3]

  - rb: tbl.between(0, 3, :index => :ai, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, 3, index='ai', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(0, 3, {'index':'ai', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3]
  - rb: tbl.between(0, 1, :index => :ai, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, 1, index='ai', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(0, 1, {'index':'ai', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3]
  - rb: tbl.between(0, 0, :index => :ai, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, 0, index='ai', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(0, 0, {'index':'ai', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3]
  - rb: tbl.between(-1, 2, :index => :ai, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(-1, 2, index='ai', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(-1, 2, {'index':'ai', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3]

  - rb: tbl.between(1, 1, :index => :ai).orderby(:id).map{|x| x[:id]}
    py: tbl.between(1, 1, index='ai').order_by('id').map(lambda x:x['id'])
    js: tbl.between(1, 1, {index:'ai'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(1, nil, :index => :ai).orderby(:id).map{|x| x[:id]}
    py: tbl.between(1, None, index='ai').order_by('id').map(lambda x:x['id'])
    js: tbl.between(1, null, {index:'ai'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [4]
  - rb: tbl.between(5, nil, :index => :ai).orderby(:id).map{|x| x[:id]}
    py: tbl.between(5, None, index='ai').order_by('id').map(lambda x:x['id'])
    js: tbl.between(5, null, {index:'ai'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(nil, 0, :index => :ai).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, 0, index='ai').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, 0, {index:'ai'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(-1, -1, :index => :ai).orderby(:id).map{|x| x[:id]}
    py: tbl.between(-1, -1, index='ai').order_by('id').map(lambda x:x['id'])
    js: tbl.between(-1, -1, {index:'ai'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(nil, -1, :index => :ai).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, -1, index='ai').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, -1, {index:'ai'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []

  - rb: tbl.between(1, 1, :index => :ai, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(1, 1, index='ai', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(1, 1, {'index':'ai', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(1, nil, :index => :ai, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(1, None, index='ai', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(1, null, {'index':'ai', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [4]
  - rb: tbl.between(5, nil, :index => :ai, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(5, None, index='ai', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(5, null, {'index':'ai', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(nil, 0, :index => :ai, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, 0, index='ai', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, 0, {'index':'ai', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3]
  - rb: tbl.between(-1, -1, :index => :ai, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(-1, -1, index='ai', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(-1, -1, {'index':'ai', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(nil, -1, :index => :ai, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, -1, index='ai', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, -1, {'index':'ai', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []

  - rb: tbl.between(0, 1, :index => :c).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, 1, index='c').order_by('id').map(lambda x:x['id'])
    js: tbl.between(0, 1, {index:'c'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1]
  - rb: tbl.between(-1, 1, :index => :c).orderby(:id).map{|x| x[:id]}
    py: tbl.between(-1, 1, index='c').order_by('id').map(lambda x:x['id'])
    js: tbl.between(-1, 1, {index:'c'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1]
  - rb: tbl.between(nil, 1, :index => :c).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, 1, index='c').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, 1, {index:'c'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1]
  - rb: tbl.between(0, nil, :index => :c).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, None, index='c').order_by('id').map(lambda x:x['id'])
    js: tbl.between(0, null, {index:'c'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(-1, nil, :index => :c).orderby(:id).map{|x| x[:id]}
    py: tbl.between(-1, None, index='c').order_by('id').map(lambda x:x['id'])
    js: tbl.between(-1, null, {index:'c'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(nil, nil, :index => :c).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, None, index='c').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, null, {index:'c'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(1, nil, :index => :c).orderby(:id).map{|x| x[:id]}
    py: tbl.between(1, None, index='c').order_by('id').map(lambda x:x['id'])
    js: tbl.between(1, null, {index:'c'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [2, 3, 4]
  - rb: tbl.between(1, 1, :index => :c).orderby(:id).map{|x| x[:id]}
    py: tbl.between(1, 1, index='c').order_by('id').map(lambda x:x['id'])
    js: tbl.between(1, 1, {index:'c'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []

  - rb: tbl.between(0, 1, :index => :c, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, 1, index='c', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(0, 1, {'index':'c', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3]
  - rb: tbl.between(-1, 1, :index => :c, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(-1, 1, index='c', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(-1, 1, {'index':'c', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3]
  - rb: tbl.between(nil, 1, :index => :c, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, 1, index='c', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, 1, {'index':'c', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3]
  - rb: tbl.between(0, nil, :index => :c, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(0, None, index='c', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(0, null, {'index':'c', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(-1, nil, :index => :c, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(-1, None, index='c', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(-1, null, {'index':'c', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(nil, nil, :index => :c, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, None, index='c', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, null, {'index':'c', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(1, nil, :index => :c, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(1, None, index='c', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(1, null, {'index':'c', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [2, 3, 4]
  - rb: tbl.between(1, 1, :index => :c, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(1, 1, index='c', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(1, 1, {'index':'c', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [2, 3]

  - rb: tbl.index_create('bc') {|row| [row[:b], row[:c]]}
    py: tbl.index_create('bc', lambda row:[row['b'], row['c']])
    js: tbl.indexCreate('bc', function(row) { return [row('b'), row('c')]; })
    ot: ({'created':1})
  - rb: tbl.index_create('cb') {|row| [row[:c], row[:b]]}
    py: tbl.index_create('cb', lambda row:[row['c'], row['b']])
    js: tbl.indexCreate('cb', function(row) { return [row('c'), row('b')]; })
    ot: ({'created':1})

  - rb: tbl.between(nil, [0, 0], :index => :bc).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, [0, 0], index='bc').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, [0, 0], {index:'bc'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(nil, [0, 0], :index => :cb).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, [0, 0], index='cb').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, [0, 0], {index:'cb'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between(nil, [0, 1], :index => :bc).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, [0, 1], index='bc').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, [0, 1], {index:'bc'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1]
  - rb: tbl.between(nil, [0, 1], :index => :cb).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, [0, 1], index='cb').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, [0, 1], {index:'cb'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1]
  - rb: tbl.between(nil, [1, 0], :index => :bc).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, [1, 0], index='bc').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, [1, 0], {index:'bc'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2]
  - rb: tbl.between(nil, [1, 0], :index => :cb).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, [1, 0], index='cb').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, [1, 0], {index:'cb'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1]
  - rb: tbl.between(nil, [1, 1], :index => :bc).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, [1, 1], index='bc').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, [1, 1], {index:'bc'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2]
  - rb: tbl.between(nil, [1, 1], :index => :cb).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, [1, 1], index='cb').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, [1, 1], {index:'cb'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2]
  - rb: tbl.between(nil, nil, :index => :bc).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, None, index='bc').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, null, {index:'bc'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(nil, nil, :index => :cb).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, None, index='cb').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, null, {index:'cb'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]

  - rb: tbl.between(nil, [0, 0], :index => :bc, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, [0, 0], index='bc', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, [0, 0], {'index':'bc', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1]
  - rb: tbl.between(nil, [0, 0], :index => :cb, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, [0, 0], index='cb', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, [0, 0], {'index':'cb', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1]
  - rb: tbl.between(nil, [0, 1], :index => :bc, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, [0, 1], index='bc', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, [0, 1], {'index':'bc', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2]
  - rb: tbl.between(nil, [0, 1], :index => :cb, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, [0, 1], index='cb', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, [0, 1], {'index':'cb', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1]
  - rb: tbl.between(nil, [1, 0], :index => :bc, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, [1, 0], index='bc', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, [1, 0], {'index':'bc', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2]
  - rb: tbl.between(nil, [1, 0], :index => :cb, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, [1, 0], index='cb', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, [1, 0], {'index':'cb', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2]
  - rb: tbl.between(nil, [1, 1], :index => :bc, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, [1, 1], index='bc', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, [1, 1], {'index':'bc', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3]
  - rb: tbl.between(nil, [1, 1], :index => :cb, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, [1, 1], index='cb', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, [1, 1], {'index':'cb', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3]
  - rb: tbl.between(nil, nil, :index => :bc, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, None, index='bc', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, null, {'index':'bc', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between(nil, nil, :index => :cb, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between(None, None, index='cb', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(null, null, {'index':'cb', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]

  - rb: tbl.between([0, 0], [0, 0], :index => :bc).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 0], [0, 0], index='bc').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 0], [0, 0], {index:'bc'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([0, 0], [0, 0], :index => :cb).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 0], [0, 0], index='cb').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 0], [0, 0], {index:'cb'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([0, 0], [0, 1], :index => :bc).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 0], [0, 1], index='bc').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 0], [0, 1], {index:'bc'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1]
  - rb: tbl.between([0, 0], [0, 1], :index => :cb).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 0], [0, 1], index='cb').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 0], [0, 1], {index:'cb'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1]
  - rb: tbl.between([0, 0], [1, 0], :index => :bc).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 0], [1, 0], index='bc').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 0], [1, 0], {index:'bc'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2]
  - rb: tbl.between([0, 0], [1, 0], :index => :cb).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 0], [1, 0], index='cb').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 0], [1, 0], {index:'cb'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1]
  - rb: tbl.between([0, 0], [1, 1], :index => :bc).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 0], [1, 1], index='bc').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 0], [1, 1], {index:'bc'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2]
  - rb: tbl.between([0, 0], [1, 1], :index => :cb).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 0], [1, 1], index='cb').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 0], [1, 1], {index:'cb'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2]
  - rb: tbl.between([0, 0], nil, :index => :bc).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 0], None, index='bc').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 0], null, {index:'bc'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between([0, 0], nil, :index => :cb).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 0], None, index='cb').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 0], null, {index:'cb'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]

  - rb: tbl.between([0, 0], [0, 0], :index => :bc, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 0], [0, 0], index='bc', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 0], [0, 0], {'index':'bc', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1]
  - rb: tbl.between([0, 0], [0, 0], :index => :cb, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 0], [0, 0], index='cb', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 0], [0, 0], {'index':'cb', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1]
  - rb: tbl.between([0, 0], [0, 1], :index => :bc, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 0], [0, 1], index='bc', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 0], [0, 2], {'index':'bc', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2]
  - rb: tbl.between([0, 0], [0, 1], :index => :cb, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 0], [0, 1], index='cb', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 0], [0, 1], {'index':'cb', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1]
  - rb: tbl.between([0, 0], [1, 0], :index => :bc, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 0], [1, 0], index='bc', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 0], [1, 0], {'index':'bc', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2]
  - rb: tbl.between([0, 0], [1, 0], :index => :cb, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 0], [1, 0], index='cb', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 0], [1, 0], {'index':'cb', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2]
  - rb: tbl.between([0, 0], [1, 1], :index => :bc, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 0], [1, 1], index='bc', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 0], [1, 1], {'index':'bc', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3]
  - rb: tbl.between([0, 0], [1, 1], :index => :cb, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 0], [1, 1], index='cb', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 0], [1, 1], {'index':'cb', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3]
  - rb: tbl.between([0, 0], nil, :index => :bc, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 0], None, index='bc', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 0], null, {'index':'bc', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]
  - rb: tbl.between([0, 0], nil, :index => :cb, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 0], None, index='cb', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 0], null, {'index':'cb', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [0, 1, 2, 3, 4]

  - rb: tbl.between([0, 1], [0, 0], :index => :bc).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 1], [0, 0], index='bc').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 1], [0, 0], {index:'bc'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([0, 1], [0, 0], :index => :cb).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 1], [0, 0], index='cb').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 1], [0, 0], {index:'cb'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([0, 1], [0, 1], :index => :bc).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 1], [0, 1], index='bc').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 1], [0, 1], {index:'bc'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([0, 1], [0, 1], :index => :cb).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 1], [0, 1], index='cb').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 1], [0, 1], {index:'cb'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([0, 1], [1, 0], :index => :bc).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 1], [1, 0], index='bc').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 1], [1, 0], {index:'bc'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [2]
  - rb: tbl.between([0, 1], [1, 0], :index => :cb).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 1], [1, 0], index='cb').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 1], [1, 0], {index:'cb'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([0, 1], [1, 1], :index => :bc).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 1], [1, 1], index='bc').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 1], [1, 1], {index:'bc'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [2]
  - rb: tbl.between([0, 1], [1, 1], :index => :cb).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 1], [1, 1], index='cb').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 1], [1, 1], {index:'cb'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [2]
  - rb: tbl.between([0, 1], nil, :index => :bc).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 1], None, index='bc').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 1], null, {index:'bc'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [2, 3, 4]
  - rb: tbl.between([0, 1], nil, :index => :cb).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 1], None, index='cb').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 1], null, {index:'cb'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [2, 3, 4]

  - rb: tbl.between([0, 1], [0, 0], :index => :bc, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 1], [0, 0], index='bc', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 1], [0, 0], {'index':'bc', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([0, 1], [0, 0], :index => :cb, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 1], [0, 0], index='cb', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 1], [0, 0], {'index':'cb', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([0, 1], [0, 1], :index => :bc, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 1], [0, 1], index='bc', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 1], [0, 1], {'index':'bc', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [2]
  - rb: tbl.between([0, 1], [0, 1], :index => :cb, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 1], [0, 1], index='cb', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 1], [0, 1], {'index':'cb', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([0, 1], [1, 0], :index => :bc, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 1], [1, 0], index='bc', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 1], [1, 0], {'index':'bc', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [2]
  - rb: tbl.between([0, 1], [1, 0], :index => :cb, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 1], [1, 0], index='cb', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 1], [1, 0], {'index':'cb', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [2]
  - rb: tbl.between([0, 1], [1, 1], :index => :bc, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 1], [1, 1], index='bc', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 1], [1, 1], {'index':'bc', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [2, 3]
  - rb: tbl.between([0, 1], [1, 1], :index => :cb, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 1], [1, 1], index='cb', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 1], [1, 1], {'index':'cb', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [2, 3]
  - rb: tbl.between([0, 1], nil, :index => :bc, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 1], None, index='bc', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 1], null, {'index':'bc', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [2, 3, 4]
  - rb: tbl.between([0, 1], nil, :index => :cb, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([0, 1], None, index='cb', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([0, 1], null, {'index':'cb', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [2, 3, 4]

  - rb: tbl.between([1, 0], [0, 0], :index => :bc).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 0], [0, 0], index='bc').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 0], [0, 0], {index:'bc'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([1, 0], [0, 0], :index => :cb).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 0], [0, 0], index='cb').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 0], [0, 0], {index:'cb'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([1, 0], [0, 1], :index => :bc).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 0], [0, 1], index='bc').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 0], [0, 1], {index:'bc'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([1, 0], [0, 1], :index => :cb).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 0], [0, 1], index='cb').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 0], [0, 1], {index:'cb'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([1, 0], [1, 0], :index => :bc).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 0], [1, 0], index='bc').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 0], [1, 0], {index:'bc'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([1, 0], [1, 0], :index => :cb).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 0], [1, 0], index='cb').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 0], [1, 0], {index:'cb'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([1, 0], [1, 1], :index => :bc).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 0], [1, 1], index='bc').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 0], [1, 1], {index:'bc'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([1, 0], [1, 1], :index => :cb).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 0], [1, 1], index='cb').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 0], [1, 1], {index:'cb'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [2]
  - rb: tbl.between([1, 0], nil, :index => :bc).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 0], None, index='bc').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 0], null, {index:'bc'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [3, 4]
  - rb: tbl.between([1, 0], nil, :index => :cb).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 0], None, index='cb').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 0], null, {index:'cb'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [2, 3, 4]

  - rb: tbl.between([1, 0], [0, 0], :index => :bc, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 0], [0, 0], index='bc', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 0], [0, 0], {'index':'bc', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([1, 0], [0, 0], :index => :cb, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 0], [0, 0], index='cb', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 0], [0, 0], {'index':'cb', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([1, 0], [0, 1], :index => :bc, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 0], [0, 1], index='bc', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 0], [0, 1], {'index':'bc', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([1, 0], [0, 1], :index => :cb, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 0], [0, 1], index='cb', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 0], [0, 1], {'index':'cb', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([1, 0], [1, 0], :index => :bc, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 0], [1, 0], index='bc', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 0], [1, 0], {'index':'bc', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([1, 0], [1, 0], :index => :cb, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 0], [1, 0], index='cb', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 0], [1, 0], {'index':'cb', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [2]
  - rb: tbl.between([1, 0], [1, 1], :index => :bc, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 0], [1, 1], index='bc', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 0], [1, 1], {'index':'bc', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [3]
  - rb: tbl.between([1, 0], [1, 1], :index => :cb, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 0], [1, 1], index='cb', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 0], [1, 1], {'index':'cb', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [2, 3]
  - rb: tbl.between([1, 0], nil, :index => :bc, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 0], None, index='bc', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 0], null, {'index':'bc', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [3, 4]
  - rb: tbl.between([1, 0], nil, :index => :cb, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 0], None, index='cb', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 0], null, {'index':'cb', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [2, 3, 4]

  - rb: tbl.between([1, 1], [0, 0], :index => :bc).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 1], [0, 0], index='bc').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 1], [0, 0], {index:'bc'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([1, 1], [0, 0], :index => :cb).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 1], [0, 0], index='cb').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 1], [0, 0], {index:'cb'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([1, 1], [0, 1], :index => :bc).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 1], [0, 1], index='bc').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 1], [0, 1], {index:'bc'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([1, 1], [0, 1], :index => :cb).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 1], [0, 1], index='cb').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 1], [0, 1], {index:'cb'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([1, 1], [1, 0], :index => :bc).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 1], [1, 0], index='bc').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 1], [1, 0], {index:'bc'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([1, 1], [1, 0], :index => :cb).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 1], [1, 0], index='cb').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 1], [1, 0], {index:'cb'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([1, 1], [1, 1], :index => :bc).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 1], [1, 1], index='bc').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 1], [1, 1], {index:'bc'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([1, 1], [1, 1], :index => :cb).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 1], [1, 1], index='cb').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 1], [1, 1], {index:'cb'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([1, 1], nil, :index => :bc).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 1], None, index='bc').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 1], null, {index:'bc'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [3, 4]
  - rb: tbl.between([1, 1], nil, :index => :cb).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 1], None, index='cb').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 1], null, {index:'cb'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [3, 4]

  - rb: tbl.between([1, 1], [0, 0], :index => :bc, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 1], [0, 0], index='bc', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 1], [0, 0], {'index':'bc', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([1, 1], [0, 0], :index => :cb, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 1], [0, 0], index='cb', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 1], [0, 0], {'index':'cb', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([1, 1], [0, 1], :index => :bc, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 1], [0, 1], index='bc', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 1], [0, 1], {'index':'bc', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([1, 1], [0, 1], :index => :cb, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 1], [0, 1], index='cb', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 1], [0, 1], {'index':'cb', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([1, 1], [1, 0], :index => :bc, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 1], [1, 0], index='bc', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 1], [1, 0], {'index':'bc', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([1, 1], [1, 0], :index => :cb, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 1], [1, 0], index='cb', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 1], [1, 0], {'index':'cb', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: []
  - rb: tbl.between([1, 1], [1, 1], :index => :bc, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 1], [1, 1], index='bc', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 1], [1, 1], {'index':'bc', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [3]
  - rb: tbl.between([1, 1], [1, 1], :index => :cb, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 1], [1, 1], index='cb', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 1], [1, 1], {'index':'cb', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [3]
  - rb: tbl.between([1, 1], nil, :index => :bc, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 1], None, index='bc', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 1], null, {'index':'bc', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [3, 4]
  - rb: tbl.between([1, 1], nil, :index => :cb, :right_bound => :closed).orderby(:id).map{|x| x[:id]}
    py: tbl.between([1, 1], None, index='cb', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between([1, 1], null, {'index':'cb', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: [3, 4]

  - rb: tbl.between(1, 3, :index => :mi, :right_bound => :closed).map{|x| x[:id]}
    py: tbl.between(1, 3, index='mi', right_bound='closed').map(lambda x:x['id'])
    js: tbl.between(1, 3, {'index':'mi', 'right_bound':'closed'}).map(function(x) { return x('id'); })
    ot: ([0,0,0])

  - rb: tbl.between(1, 16, :index => :mi, :right_bound => :closed).order_by(:id).map{|x| x[:id]}
    py: tbl.between(1, 16, index='mi', right_bound='closed').order_by('id').map(lambda x:x['id'])
    js: tbl.between(1, 16, {'index':'mi', 'right_bound':'closed'}).orderBy('id').map(function(x) { return x('id'); })
    ot: ([0,0,0,1,1,1,2,3,3,3,4,4,4])

  - rb: tbl.order_by(:index => :mi).map{|x| x[:id]}
    py: tbl.order_by(index='mi').map(lambda x:x['id'])
    js: tbl.orderBy({'index':'mi'}).map(function(x) { return x('id'); })
    ot: ([0,0,0,1,1,1,2,3,3,3,4,4,4])


  - cd: r.db('test').table_drop('sindex_api')
