add batch remove batch split batch comment selection show hidden batches hide batch highlight batch
db<>fiddle
donate feedback about
By using db<>fiddle, you agree to license everything you submit by Creative Commons CC0.
Help with an interesting Postgres question: Why isn't an Index Only Scan used on a partition accessed via the parent table?.
CREATE TABLE
CREATE VIEW
CREATE FUNCTION
CREATE TRIGGER
INSERT 0 1
id name
0 foo
SELECT 1
id name site_id
0 foo null
SELECT 1
ERROR:  Unexpected site_id: <NULL>
CONTEXT:  PL/pgSQL function trg_ins_tbl() line 13 at RAISE
INSERT 0 1
INSERT 0 1
INSERT 0 0
INSERT 0 0
id name
0 foo
1 bar
2 baz
3 bam
SELECT 4
id name site_id
0 foo null
1 bar null
2 baz null
3 bam null
SELECT 4
INSERT 0 1
id name
0 foo
1 bar
2 baz
3 bam
4 test
SELECT 5