text: -- original: boundary3.test
  -- credit:   http://www.sqlite.org/src/tree?ci=trunk&name=test
  
  SELECT t2.* FROM t1 JOIN t2 USING(a) WHERE x='ffffffffffffff80'
  ;SELECT t1.rowid, x FROM t1 JOIN t2 ON t2.r=t1.rowid WHERE t2.a=53
  ;SELECT t2.a FROM t1 JOIN t2 USING(a)
       WHERE t1.rowid > -128 ORDER BY t2.a
  ;SELECT t2.a FROM t2 NATURAL JOIN t1
       WHERE t1.rowid > -128 ORDER BY t1.a DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid > t2.r
       WHERE t2.a=53
       ORDER BY t1.rowid
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid > t2.r
       WHERE t2.a=53
       ORDER BY t1.rowid DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid > t2.r
       WHERE t2.a=53
       ORDER BY x
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid > CAST(t2.r AS real)
       WHERE t2.a=53
       ORDER BY t1.rowid
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid > CAST(t2.r AS real)
       WHERE t2.a=53
       ORDER BY t1.rowid DESC
  ;SELECT t2.a FROM t1 JOIN t2 USING(a)
       WHERE t1.rowid >= -128 ORDER BY t2.a
  ;SELECT t2.a FROM t2 NATURAL JOIN t1
       WHERE t1.rowid >= -128 ORDER BY t1.a DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid >= t2.r
       WHERE t2.a=53
       ORDER BY t1.rowid
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid >= t2.r
       WHERE t2.a=53
       ORDER BY t1.rowid DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid >= t2.r
       WHERE t2.a=53
       ORDER BY x
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid >= CAST(t2.r AS real)
       WHERE t2.a=53
       ORDER BY t1.rowid
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid >= CAST(t2.r AS real)
       WHERE t2.a=53
       ORDER BY t1.rowid DESC
  ;SELECT t2.a FROM t1 JOIN t2 USING(a)
       WHERE t1.rowid < -128 ORDER BY t2.a
  ;SELECT t2.a FROM t2 NATURAL JOIN t1
       WHERE t1.rowid < -128 ORDER BY t1.a DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid < t2.r
       WHERE t2.a=53
       ORDER BY t1.rowid
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid < t2.r
       WHERE t2.a=53
       ORDER BY t1.rowid DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid < t2.r
       WHERE t2.a=53
       ORDER BY x
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid < CAST(t2.r AS real)
       WHERE t2.a=53
       ORDER BY t1.rowid
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid < CAST(t2.r AS real)
       WHERE t2.a=53
       ORDER BY t1.rowid DESC
  ;SELECT t2.a FROM t1 JOIN t2 USING(a)
       WHERE t1.rowid <= -128 ORDER BY t2.a
  ;SELECT t2.a FROM t2 NATURAL JOIN t1
       WHERE t1.rowid <= -128 ORDER BY t1.a DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid <= t2.r
       WHERE t2.a=53
       ORDER BY t1.rowid
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid <= t2.r
       WHERE t2.a=53
       ORDER BY t1.rowid DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid <= t2.r
       WHERE t2.a=53
       ORDER BY x
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid <= CAST(t2.r AS real)
       WHERE t2.a=53
       ORDER BY t1.rowid
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid <= CAST(t2.r AS real)
       WHERE t2.a=53
       ORDER BY t1.rowid DESC
  ;SELECT t1.* FROM t1, t2 WHERE t1.rowid=72057594037927936 AND t2.a=t1.a
  ;SELECT t2.* FROM t1 JOIN t2 USING(a) WHERE x='0100000000000000'
  ;SELECT t1.rowid, x FROM t1 JOIN t2 ON t2.r=t1.rowid WHERE t2.a=28
  ;SELECT t2.a FROM t1 JOIN t2 USING(a)
       WHERE t1.rowid > 72057594037927936 ORDER BY t2.a
  ;SELECT t2.a FROM t2 NATURAL JOIN t1
       WHERE t1.rowid > 72057594037927936 ORDER BY t1.a DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid > t2.r
       WHERE t2.a=28
       ORDER BY t1.rowid
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid > t2.r
       WHERE t2.a=28
       ORDER BY t1.rowid DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid > t2.r
       WHERE t2.a=28
       ORDER BY x
  ;SELECT t2.a FROM t1 JOIN t2 USING(a)
       WHERE t1.rowid >= 72057594037927936 ORDER BY t2.a
  ;SELECT t2.a FROM t2 NATURAL JOIN t1
       WHERE t1.rowid >= 72057594037927936 ORDER BY t1.a DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid >= t2.r
       WHERE t2.a=28
       ORDER BY t1.rowid
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid >= t2.r
       WHERE t2.a=28
       ORDER BY t1.rowid DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid >= t2.r
       WHERE t2.a=28
       ORDER BY x
  ;SELECT t2.a FROM t1 JOIN t2 USING(a)
       WHERE t1.rowid < 72057594037927936 ORDER BY t2.a
  ;SELECT t2.a FROM t2 NATURAL JOIN t1
       WHERE t1.rowid < 72057594037927936 ORDER BY t1.a DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid < t2.r
       WHERE t2.a=28
       ORDER BY t1.rowid
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid < t2.r
       WHERE t2.a=28
       ORDER BY t1.rowid DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid < t2.r
       WHERE t2.a=28
       ORDER BY x
  ;SELECT t2.a FROM t1 JOIN t2 USING(a)
       WHERE t1.rowid <= 72057594037927936 ORDER BY t2.a
  ;SELECT t2.a FROM t2 NATURAL JOIN t1
       WHERE t1.rowid <= 72057594037927936 ORDER BY t1.a DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid <= t2.r
       WHERE t2.a=28
       ORDER BY t1.rowid
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid <= t2.r
       WHERE t2.a=28
       ORDER BY t1.rowid DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid <= t2.r
       WHERE t2.a=28
       ORDER BY x
  ;SELECT t1.* FROM t1, t2 WHERE t1.rowid=2147483648 AND t2.a=t1.a
  ;SELECT t2.* FROM t1 JOIN t2 USING(a) WHERE x='0000000080000000'
  ;SELECT t1.rowid, x FROM t1 JOIN t2 ON t2.r=t1.rowid WHERE t2.a=51
  ;SELECT t2.a FROM t1 JOIN t2 USING(a)
       WHERE t1.rowid > 2147483648 ORDER BY t2.a
  ;SELECT t2.a FROM t2 NATURAL JOIN t1
       WHERE t1.rowid > 2147483648 ORDER BY t1.a DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid > t2.r
       WHERE t2.a=51
       ORDER BY t1.rowid
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid > t2.r
       WHERE t2.a=51
       ORDER BY t1.rowid DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid > t2.r
       WHERE t2.a=51
       ORDER BY x
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid > CAST(t2.r AS real)
       WHERE t2.a=51
       ORDER BY t1.rowid
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid > CAST(t2.r AS real)
       WHERE t2.a=51
       ORDER BY t1.rowid DESC
  ;SELECT t2.a FROM t1 JOIN t2 USING(a)
       WHERE t1.rowid >= 2147483648 ORDER BY t2.a
  ;SELECT t2.a FROM t2 NATURAL JOIN t1
       WHERE t1.rowid >= 2147483648 ORDER BY t1.a DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid >= t2.r
       WHERE t2.a=51
       ORDER BY t1.rowid
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid >= t2.r
       WHERE t2.a=51
       ORDER BY t1.rowid DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid >= t2.r
       WHERE t2.a=51
       ORDER BY x
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid >= CAST(t2.r AS real)
       WHERE t2.a=51
       ORDER BY t1.rowid
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid >= CAST(t2.r AS real)
       WHERE t2.a=51
       ORDER BY t1.rowid DESC
  ;SELECT t2.a FROM t1 JOIN t2 USING(a)
       WHERE t1.rowid < 2147483648 ORDER BY t2.a
  ;SELECT t2.a FROM t2 NATURAL JOIN t1
       WHERE t1.rowid < 2147483648 ORDER BY t1.a DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid < t2.r
       WHERE t2.a=51
       ORDER BY t1.rowid
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid < t2.r
       WHERE t2.a=51
       ORDER BY t1.rowid DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid < t2.r
       WHERE t2.a=51
       ORDER BY x
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid < CAST(t2.r AS real)
       WHERE t2.a=51
       ORDER BY t1.rowid
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid < CAST(t2.r AS real)
       WHERE t2.a=51
       ORDER BY t1.rowid DESC
  ;SELECT t2.a FROM t1 JOIN t2 USING(a)
       WHERE t1.rowid <= 2147483648 ORDER BY t2.a
  ;SELECT t2.a FROM t2 NATURAL JOIN t1
       WHERE t1.rowid <= 2147483648 ORDER BY t1.a DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid <= t2.r
       WHERE t2.a=51
       ORDER BY t1.rowid
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid <= t2.r
       WHERE t2.a=51
       ORDER BY t1.rowid DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid <= t2.r
       WHERE t2.a=51
       ORDER BY x
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid <= CAST(t2.r AS real)
       WHERE t2.a=51
       ORDER BY t1.rowid
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid <= CAST(t2.r AS real)
       WHERE t2.a=51
       ORDER BY t1.rowid DESC
  ;SELECT t1.* FROM t1, t2 WHERE t1.rowid=549755813887 AND t2.a=t1.a
  ;SELECT t2.* FROM t1 JOIN t2 USING(a) WHERE x='0000007fffffffff'
  ;SELECT t1.rowid, x FROM t1 JOIN t2 ON t2.r=t1.rowid WHERE t2.a=46
  ;SELECT t2.a FROM t1 JOIN t2 USING(a)
       WHERE t1.rowid > 549755813887 ORDER BY t2.a
  ;SELECT t2.a FROM t2 NATURAL JOIN t1
       WHERE t1.rowid > 549755813887 ORDER BY t1.a DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid > t2.r
       WHERE t2.a=46
       ORDER BY t1.rowid
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid > t2.r
       WHERE t2.a=46
       ORDER BY t1.rowid DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid > t2.r
       WHERE t2.a=46
       ORDER BY x
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid > CAST(t2.r AS real)
       WHERE t2.a=46
       ORDER BY t1.rowid
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid > CAST(t2.r AS real)
       WHERE t2.a=46
       ORDER BY t1.rowid DESC
  ;SELECT t2.a FROM t1 JOIN t2 USING(a)
       WHERE t1.rowid >= 549755813887 ORDER BY t2.a
  ;SELECT t2.a FROM t2 NATURAL JOIN t1
       WHERE t1.rowid >= 549755813887 ORDER BY t1.a DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid >= t2.r
       WHERE t2.a=46
       ORDER BY t1.rowid
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid >= t2.r
       WHERE t2.a=46
       ORDER BY t1.rowid DESC
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid >= t2.r
       WHERE t2.a=46
       ORDER BY x
  ;SELECT t1.a FROM t1 JOIN t2 ON t1.rowid >= CAST(t2.r AS real)
       WHERE t2.a=46
       ORDER BY t1.rowid;