📄 inbetween.out
字号:
V --------------------------------------------------everyone is here noone is there ij> select d from t;D ----------------------NULL 200.0 -200.0 800.0 -800.0 ij> select d from t where d in (200, -800);D ----------------------200.0 -800.0 ij> select r from t;R -------------NULL 300.0 -300.0 1000.0 -10300.0 ij> select r from t where r in (300.0, -10300.0);R -------------300.0 -10300.0 ij> select e from t;E ----------NULL 1992-01-011992-01-021892-01-012992-01-02ij> select e from t where e in ('2992-01-02', '3999-08-08', '1992-01-02');E ----------1992-01-022992-01-02ij> select t from t;T --------NULL 12:30:3012:30:5907:30:3019:30:59ij> select t from t where t in ('12:30:58', '07:20:20', '07:30:30');T --------07:30:30ij> -- verify that added predicates getting pushed downselect p from t;P --------------------------NULL xxxxxxFILTERED-TIMESTAMPxxxxxxxxxxxFILTERED-TIMESTAMPxxxxxxxxxxxFILTERED-TIMESTAMPxxxxxxxxxxxFILTERED-TIMESTAMPxxxxxij> select p from t where p in ('xxxxxxFILTERED-TIMESTAMPxxxxx', 'xxxxxxFILTERED-TIMESTAMPxxxxx', 'xxxxxxFILTERED-TIMESTAMPxxxxx');P --------------------------xxxxxxFILTERED-TIMESTAMPxxxxxij> call SYSCS_UTIL.SYSCS_SET_RUNTIMESTATISTICS(1);0 rows inserted/updated/deletedij> maximumdisplaywidth 2000;ij> values SYSCS_UTIL.SYSCS_GET_RUNTIMESTATISTICS();1 ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------Statement Name: nullStatement Text: call SYSCS_UTIL.SYSCS_SET_RUNTIMESTATISTICS(1)Parse Time: 0Bind Time: 0Optimize Time: 0Generate Time: 0Compile Time: 0Execute Time: 0Begin Compilation Timestamp : nullEnd Compilation Timestamp : nullBegin Execution Timestamp : nullEnd Execution Timestamp : nullStatement Execution Plan Text: null ij> -- big in lists (test binary search)create table big(i int, c char(10));0 rows inserted/updated/deletedij> insert into big values (1, '1'), (2, '2'), (3, '3'), (4, '4'), (5, '5'), (6, '6'), (7, '7'), (8, '8'), (9, '9'), (10, '10'), (11, '11'), (12, '12'), (13, '13'), (14, '14'), (15, '15'), (16, '16'), (17, '17'), (18, '18'), (19, '19'), (20, '20'), (21, '21'), (22, '22'), (23, '23'), (24, '24'), (25, '25'), (26, '26'), (27, '27'), (28, '28'), (29, '29'), (30, '30');30 rows inserted/updated/deletedij> select * from big where i in (1, 3, 5, 7, 9, 11, 13, 15, 17, 19, 21, 23, 25, 27, 29, 31);I |C ----------------------1 |1 3 |3 5 |5 7 |7 9 |9 11 |11 13 |13 15 |15 17 |17 19 |19 21 |21 23 |23 25 |25 27 |27 29 |29 ij> select * from big where i in (31, 32, 5, 7, 9, 11, 13, 15, 17, 19, 21, 23, 25, 27, 29, 1);I |C ----------------------1 |1 5 |5 7 |7 9 |9 11 |11 13 |13 15 |15 17 |17 19 |19 21 |21 23 |23 25 |25 27 |27 29 |29 ij> select * from big where i in (1, 5, 7, 9, 11, 13, 15, 17, 19, 21, 23, 25, 27, 29, 31);I |C ----------------------1 |1 5 |5 7 |7 9 |9 11 |11 13 |13 15 |15 17 |17 19 |19 21 |21 23 |23 25 |25 27 |27 29 |29 ij> select * from big where i in (1, 5, 7, 9, 13, 15, 17, 19, 21, 23, 25, 27, 29, 31);I |C ----------------------1 |1 5 |5 7 |7 9 |9 13 |13 15 |15 17 |17 19 |19 21 |21 23 |23 25 |25 27 |27 29 |29 ij> select * from big where i in (1, 5, 7, 9, 13, 15, 17, 19, 23, 25, 27, 29, 31);I |C ----------------------1 |1 5 |5 7 |7 9 |9 13 |13 15 |15 17 |17 19 |19 23 |23 25 |25 27 |27 29 |29 ij> select * from big where i in (3, 3, 3, 3);I |C ----------------------3 |3 ij> select * from big where i in (4, 4, 4, 4);I |C ----------------------4 |4 ij> select * from big where c in (1, 3, 5, 7, 9, 11, 13, 15, 17, 19, 21, 23, 25, 27, 29, 31);ERROR 42818: Comparisons between 'CHAR' and 'INTEGER' are not supported.ij> select * from big where c in (31, 32, 5, 7, 9, 11, 13, 15, 17, 19, 21, 23, 25, 27, 29, 1);ERROR 42818: Comparisons between 'CHAR' and 'INTEGER' are not supported.ij> select * from big where c in (1, 5, 7, 9, 11, 13, 15, 17, 19, 21, 23, 25, 27, 29, 31);ERROR 42818: Comparisons between 'CHAR' and 'INTEGER' are not supported.ij> select * from big where c in (1, 5, 7, 9, 13, 15, 17, 19, 21, 23, 25, 27, 29, 31);ERROR 42818: Comparisons between 'CHAR' and 'INTEGER' are not supported.ij> select * from big where c in ('1', '5', '7', '9', '13', '15', '17', '19', '21', '23', '25', '27', '29', '31');I |C ----------------------1 |1 5 |5 7 |7 9 |9 13 |13 15 |15 17 |17 19 |19 21 |21 23 |23 25 |25 27 |27 29 |29 ij> select * from big where i in (1, 5, 7, 9, 13, 15, 17, 19, 23, 25, 27, 29, 31);I |C ----------------------1 |1 5 |5 7 |7 9 |9 13 |13 15 |15 17 |17 19 |19 23 |23 25 |25 27 |27 29 |29 ij> -- check consistency of scans, etc.values ConsistencyChecker();1 ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------No open scans, etc.2 dependencies found ij> -- beetle 4316, check "in" with self-reference and correlation, etc.create table t1 (c1 real, c2 real);0 rows inserted/updated/deletedij> create index i11 on t1 (c1);0 rows inserted/updated/deletedij> create table t2 (c1 real, c2 real);0 rows inserted/updated/deletedij> insert into t1 values (2, 1), (3, 9), (8, 63), (5, 25), (20, 5);5 rows inserted/updated/deletedij> insert into t2 values (4, 8), (8, 8), (7, 6), (5, 6);4 rows inserted/updated/deletedij> select c1 from t1 where c1 in (2, sqrt(c2));C1 -------------2.0 3.0 5.0 ij> select c1 from t1 where c1 in ('10', '5', '20') and c1 > 3and c1 < 19;ERROR 42818: Comparisons between 'REAL' and 'CHAR' are not supported.ij> call SYSCS_UTIL.SYSCS_SET_RUNTIMESTATISTICS(1);0 rows inserted/updated/deletedij> maximumdisplaywidth 4000;ij> -- nested loop exists join, right side should be ProjectRestrict on index scan with start and stop keysselect c1 from t2 where c1 in (select c1 from t1 where c1 in (5, t2.c2));C1 -------------8.0 5.0 ij> values SYSCS_UTIL.SYSCS_GET_RUNTIMESTATISTICS();1 ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------Statement Name: nullStatement Text: -- nested loop exists join, right side should be ProjectRestrict on index scan with start and stop keysselect c1 from t2 where c1 in (select c1 from t1 where c1 in (5, t2.c2))Parse Time: 0Bind Time: 0Optimize Time: 0Generate Time: 0Compile Time: 0Execute Time: 0Begin Compilation Timestamp : nullEnd Compilation Timestamp : nullBegin Execution Timestamp : null
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -