From: | Eugene Pazhitnov <pazhitnov(at)gmail(dot)com> |
---|---|
To: | pgsql-general(at)lists(dot)postgresql(dot)org |
Subject: | pg_repack: WARNING: relation must have a primary key or not-null unique keys |
Date: | 2020-06-16 10:52:32 |
Message-ID: | CAGfKbEz-fhvhdfmrBmVFq4Jh0ftF+mSKW0Kr=1kYA1Um7AN-Hw@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Hello everyone!
eugene(at)dignus:/var/www/html/health$ psql xbox
Timing is on.
psql (12.3 (Ubuntu 12.3-1.pgdg20.04+1))
Type "help" for help.
xbox=> \d herostat
Table "public.herostat"
Column | Type | Collation | Nullable | Default
----------+------------------+-----------+----------+---------
xuid | bigint | | not null |
titleid | bigint | | not null |
value | text | | |
valfloat | double precision | | |
heroid | integer | | not null |
Indexes:
"herostat_pkey" PRIMARY KEY, btree (xuid, titleid, heroid) INCLUDE
(valfloat)
"herostat_heroid_idx" btree (heroid)
"herostat_titleid_idx" btree (titleid)
Triggers:
herostat_min_update BEFORE UPDATE ON herostat FOR EACH ROW EXECUTE
FUNCTION suppress_redundant_updates_trigger()
xbox=> \q
eugene(at)dignus:/var/www/html/health$ sudo -u postgres pg_repack -t herostat
-N -d xbox
INFO: Dry run enabled, not executing repack
WARNING: relation "public.herostat" must have a primary key or not-null
unique keys
eugene(at)dignus:/var/www/html/health$ pg_repack --version
pg_repack 1.4.5
eugene(at)dignus:/var/www/html/health$
What is wrong and what I can do to fix it?
--
Evgeny Pazhitnov
From | Date | Subject | |
---|---|---|---|
Next Message | Laurenz Albe | 2020-06-16 13:49:38 | Re: Something else about Redo Logs disappearing |
Previous Message | Bruce Momjian | 2020-06-16 10:00:38 | Re: Index no longer being used, destroying and recreating it restores use. |