By using db<>fiddle, you agree to license everything you submit by Creative Commons CC0.
40000 rows affected
| arr | chk_simpl | chk_michael | chk_bool_and | chk_exist |
|---|---|---|---|---|
| {1,2,NULL,3} | f | f | f | f |
| {1,1,1} | f | f | f | f |
| {2,2,2} | f | f | f | f |
| {NULL,NULL,NULL} | t | t | t | t |
| {} | f | t | null | t |
| QUERY PLAN |
|---|
| Seq Scan on t (cost=0.00..1734.00 rows=40000 width=1) (actual rows=40000 loops=1) |
| Planning Time: 0.057 ms |
| Execution Time: 8.820 ms |
| QUERY PLAN |
|---|
| Seq Scan on t (cost=0.00..5084.00 rows=40000 width=1) (actual rows=40000 loops=1) |
| SubPlan 1 |
| -> Result (cost=0.00..0.19 rows=10 width=1) (actual rows=2 loops=40000) |
| -> ProjectSet (cost=0.00..0.07 rows=10 width=4) (actual rows=2 loops=40000) |
| -> Result (cost=0.00..0.01 rows=1 width=0) (actual rows=1 loops=40000) |
| Planning Time: 0.043 ms |
| Execution Time: 30.601 ms |
| QUERY PLAN |
|---|
| Seq Scan on t (cost=0.00..6234.00 rows=40000 width=1) (actual rows=40000 loops=1) |
| SubPlan 1 |
| -> Aggregate (cost=0.13..0.14 rows=1 width=1) (actual rows=1 loops=40000) |
| -> Function Scan on unnest e (cost=0.00..0.10 rows=10 width=4) (actual rows=3 loops=40000) |
| Planning Time: 0.053 ms |
| Execution Time: 101.271 ms |
| QUERY PLAN |
|---|
| Seq Scan on t (cost=0.00..1814.00 rows=40000 width=1) (actual rows=40000 loops=1) |
| SubPlan 1 |
| -> HashSetOp Except (cost=0.00..0.27 rows=10 width=8) (actual rows=1 loops=40000) |
| -> Append (cost=0.00..0.24 rows=11 width=8) (actual rows=4 loops=40000) |
| -> Subquery Scan on "*SELECT* 1" (cost=0.00..0.17 rows=10 width=8) (actual rows=3 loops=40000) |
| -> ProjectSet (cost=0.00..0.07 rows=10 width=4) (actual rows=3 loops=40000) |
| -> Result (cost=0.00..0.01 rows=1 width=0) (actual rows=1 loops=40000) |
| -> Subquery Scan on "*SELECT* 2" (cost=0.00..0.02 rows=1 width=8) (actual rows=1 loops=40000) |
| -> Result (cost=0.00..0.01 rows=1 width=4) (actual rows=1 loops=40000) |
| Planning Time: 0.093 ms |
| Execution Time: 118.922 ms |