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 bars_bar (id int primary key);
CREATE TABLE foos_foo (id int primary key, bar_id int);
CREATE INDEX foos_foo_bar_id_efb062ad ON foos_foo(bar_id);
ALTER TABLE "foos_foo" ADD CONSTRAINT "foos_foo_bar_id_efb062ad_fk_foos_bar_id"
FOREIGN KEY ("bar_id")
REFERENCES "bars_bar" ("id")
DEFERRABLE INITIALLY DEFERRED;
CREATE TABLE
CREATE TABLE
CREATE INDEX
ALTER TABLE
DROP INDEX IF EXISTS "foos_foo_bar_id_efb062ad";
DROP INDEX