add remove split language chart show hidden hide
db<>fiddle
donate feedback about
By using db<>fiddle, you agree to license everything you submit by Creative Commons CC0.
version
PostgreSQL 11.13 on x86_64-pc-linux-gnu, compiled by gcc (GCC) 8.4.1 20200928 (Red Hat 8.4.1-1), 64-bit
1 rows affected
n m
3 5
unnest
1
2
3
3
2
1
1
2
3
3
2
1
1
2
3
3
2
1
1
2
3
3
2
1
1
2
3
3
2
1
QUERY PLAN
ProjectSet (cost=127.81..650.32 rows=100000 width=4) (actual time=0.040..0.046 rows=30 loops=1)
  Output: unnest(($2))
  Buffers: shared hit=3
  -> ProjectSet (cost=127.81..132.82 rows=1000 width=36) (actual time=0.039..0.041 rows=5 loops=1)
        Output: $2, generate_series(1, $3)
        Buffers: shared hit=3
        InitPlan 3 (returns $2)
          -> Append (cost=65.20..95.20 rows=2000 width=4) (actual time=0.018..0.031 rows=6 loops=1)
                Buffers: shared hit=2
                InitPlan 1 (returns $0)
                  -> Seq Scan on public.param (cost=0.00..32.60 rows=2260 width=4) (actual time=0.006..0.007 rows=1 loops=1)
                        Output: param.n
                        Buffers: shared hit=1
                InitPlan 2 (returns $1)
                  -> Seq Scan on public.param param_1 (cost=0.00..32.60 rows=2260 width=4) (actual time=0.004..0.004 rows=1 loops=1)
                        Output: param_1.n
                        Buffers: shared hit=1
                -> Function Scan on pg_catalog.generate_series x (cost=0.00..10.00 rows=1000 width=4) (actual time=0.017..0.018 rows=3 loops=1)
                      Output: x.x
                      Function Call: generate_series(1, $0)
                      Buffers: shared hit=1
                -> Function Scan on pg_catalog.generate_series x_1 (cost=0.00..10.00 rows=1000 width=4) (actual time=0.011..0.011 rows=3 loops=1)
                      Output: x_1.x
                      Function Call: generate_series($1, 1, '-1'::integer)
                      Buffers: shared hit=1
        InitPlan 4 (returns $3)
          -> Seq Scan on public.param param_2 (cost=0.00..32.60 rows=2260 width=4) (actual time=0.004..0.004 rows=1 loops=1)
                Output: param_2.m
                Buffers: shared hit=1
        -> Result (cost=0.00..0.01 rows=1 width=0) (actual time=0.000..0.001 rows=1 loops=1)
Planning Time: 0.152 ms
Execution Time: 0.111 ms