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.
CREATE TABLE
INSERT 0 100000
VACUUM
id payload dt
90001 6beb5f589a9fd04c21fcd50db3d9c80c 2024-08-08 13:44:09.692782+01
90002 400df0aa82bc46e49e2247dc5da23810 2024-08-08 13:44:09.692782+01
90003 9898c086a1392b56eea59a0a7f040906 2024-08-08 13:44:09.692782+01
90004 226a98f6949e5d6947877bc6a15e39d4 2024-08-08 13:44:09.692782+01
90005 9c4a06e4dddceb70722de4f3fda4f2c7 2024-08-08 13:44:09.692782+01
90006 23da6eee3d452c3c3ea8e61068369229 2024-08-08 13:44:09.692782+01
90007 996a7121b7bfa4c1754abbf8d46405af 2024-08-08 13:44:09.692782+01
90008 2ef85f2ae5e56041ded26f67e18136be 2024-08-08 13:44:09.692782+01
90009 b312a491b1d6b93b96f06a15fd830918 2024-08-08 13:44:09.692782+01
90010 1582166aa8006058e0d0eed662e580c5 2024-08-08 13:44:09.692782+01
SELECT 10
QUERY PLAN
WindowAgg (cost=0.00..3435.00 rows=100000 width=85) (actual rows=100000 loops=1)
  -> Seq Scan on foo (cost=0.00..1935.00 rows=100000 width=77) (actual rows=100000 loops=1)
Planning Time: 0.112 ms
Execution Time: 127.400 ms
EXPLAIN
QUERY PLAN
WindowAgg (cost=0.00..3185.00 rows=100000 width=53) (actual rows=100000 loops=1)
  -> Seq Scan on foo (cost=0.00..1935.00 rows=100000 width=45) (actual rows=100000 loops=1)
Planning Time: 0.067 ms
Execution Time: 96.480 ms
EXPLAIN
QUERY PLAN
Seq Scan on foo (cost=2185.01..4120.01 rows=100000 width=53) (actual rows=100000 loops=1)
  InitPlan 1 (returns $0)
    -> Aggregate (cost=2185.00..2185.01 rows=1 width=8) (actual rows=1 loops=1)
          -> Seq Scan on foo foo_1 (cost=0.00..1935.00 rows=100000 width=0) (actual rows=100000 loops=1)
Planning Time: 0.226 ms
Execution Time: 38.298 ms
EXPLAIN
QUERY PLAN
Seq Scan on foo (cost=0.00..1935.00 rows=100000 width=37) (actual rows=100000 loops=1)
Planning Time: 0.057 ms
Execution Time: 16.672 ms
EXPLAIN
QUERY PLAN
Seq Scan on foo (cost=0.00..1935.00 rows=100000 width=45) (actual rows=100000 loops=1)
Planning Time: 0.055 ms
Execution Time: 7.111 ms
EXPLAIN
QUERY PLAN
Seq Scan on foo (cost=0.00..1935.00 rows=100000 width=4) (actual rows=100000 loops=1)
Planning Time: 0.109 ms
Execution Time: 11.787 ms
EXPLAIN
QUERY PLAN
Aggregate (cost=2185.00..2185.01 rows=1 width=8) (actual rows=1 loops=1)
  -> Seq Scan on foo (cost=0.00..1935.00 rows=100000 width=0) (actual rows=100000 loops=1)
Planning Time: 0.074 ms
Execution Time: 9.352 ms
EXPLAIN
QUERY PLAN
WindowAgg (cost=0.00..3435.00 rows=100000 width=44) (actual rows=100000 loops=1)
  -> Seq Scan on foo (cost=0.00..1935.00 rows=100000 width=36) (actual rows=100000 loops=1)
Planning Time: 0.067 ms
Execution Time: 68.704 ms
EXPLAIN
QUERY PLAN
WindowAgg (cost=0.00..3185.00 rows=100000 width=12) (actual rows=100000 loops=1)
  -> Seq Scan on foo (cost=0.00..1935.00 rows=100000 width=4) (actual rows=100000 loops=1)
Planning Time: 0.080 ms
Execution Time: 62.477 ms
EXPLAIN
QUERY PLAN
Index Scan using foo_pkey on foo (cost=0.29..11.79 rows=125 width=37) (actual rows=133 loops=1)
  Index Cond: ((id > 66666) AND (id < 66800))
Planning Time: 0.237 ms
Execution Time: 0.093 ms
EXPLAIN
QUERY PLAN
WindowAgg (cost=0.29..13.36 rows=125 width=45) (actual rows=133 loops=1)
  -> Index Scan using foo_pkey on foo (cost=0.29..11.79 rows=125 width=37) (actual rows=133 loops=1)
        Index Cond: ((id > 66666) AND (id < 66800))
Planning Time: 0.062 ms
Execution Time: 0.122 ms
EXPLAIN
QUERY PLAN
Index Scan using foo_pkey on foo (cost=5.29..16.79 rows=125 width=45) (actual rows=133 loops=1)
  Index Cond: ((id > 66666) AND (id < 66800))
  InitPlan 1 (returns $0)
    -> Aggregate (cost=4.99..5.00 rows=1 width=8) (actual rows=1 loops=1)
          -> Index Only Scan using foo_pkey on foo foo_1 (cost=0.29..4.91 rows=31 width=0) (actual rows=33 loops=1)
                Index Cond: ((id > 66666) AND (id < 66700))
                Heap Fetches: 0
Planning Time: 0.119 ms
Execution Time: 0.105 ms
EXPLAIN
QUERY PLAN
WindowAgg (cost=0.29..8.36 rows=125 width=12) (actual rows=133 loops=1)
  -> Index Only Scan using foo_pkey on foo (cost=0.29..6.79 rows=125 width=4) (actual rows=133 loops=1)
        Index Cond: ((id > 66666) AND (id < 66800))
        Heap Fetches: 0
Planning Time: 0.057 ms
Execution Time: 0.089 ms
EXPLAIN
QUERY PLAN
Seq Scan on foo (cost=0.00..2185.00 rows=10 width=37) (actual rows=411 loops=1)
  Filter: (payload ~~ '9c%'::text)
  Rows Removed by Filter: 99589
Planning Time: 0.190 ms
Execution Time: 13.506 ms
EXPLAIN
QUERY PLAN
WindowAgg (cost=0.00..2185.12 rows=10 width=45) (actual rows=411 loops=1)
  -> Seq Scan on foo (cost=0.00..2185.00 rows=10 width=37) (actual rows=411 loops=1)
        Filter: (payload ~~ '9c%'::text)
        Rows Removed by Filter: 99589
Planning Time: 0.081 ms
Execution Time: 13.757 ms
EXPLAIN
QUERY PLAN
Seq Scan on foo (cost=2185.04..4370.03 rows=10 width=45) (actual rows=411 loops=1)
  Filter: (payload ~~ '9c%'::text)
  Rows Removed by Filter: 99589
  InitPlan 1 (returns $0)
    -> Aggregate (cost=2185.03..2185.04 rows=1 width=8) (actual rows=1 loops=1)
          -> Seq Scan on foo foo_1 (cost=0.00..2185.00 rows=10 width=0) (actual rows=411 loops=1)
                Filter: (payload ~~ '9c%'::text)
                Rows Removed by Filter: 99589
Planning Time: 0.130 ms
Execution Time: 26.493 ms
EXPLAIN