Re: pg_dump issue : Cannot drop a non-existent(?) trigger - Mailing list pgsql-hackers
From | Stephan Szabo |
---|---|
Subject | Re: pg_dump issue : Cannot drop a non-existent(?) trigger |
Date | |
Msg-id | 20050325055728.A98363@megazone.bigpanda.com Whole thread Raw |
In response to | pg_dump issue : Cannot drop a non-existent(?) trigger (Devrim GUNDUZ <devrim@gunduz.org>) |
Responses |
Re: pg_dump issue : Cannot drop a non-existent(?) trigger
(Tom Lane <tgl@sss.pgh.pa.us>)
Re: pg_dump issue : Cannot drop a non-existent(?) trigger (Devrim GUNDUZ <devrim@gunduz.org>) |
List | pgsql-hackers |
On Fri, 25 Mar 2005, Devrim GUNDUZ wrote: > - -------------------------------------------------------------------------------------------------------------- > PostgreSQL 8.0.1 on i686-redhat-linux-gnu, compiled by GCC gcc (GCC) > 3.2.3 20030502 (Red Hat Linux 3.2.3-42) > ======================================================================= > > We wanted to take a full backup, so ran pg_dump,but got an error: > > ======================================================================= > $ pg_dump prod -U postgres > all.pgdump > pg_dump: invalid argument string (firma_moduller_firma_fkey1) for trigger > "RI_ConstraintTrigger_39053" on table "t_firma_moduller" > ======================================================================= > > Looking at the details, we saw the trigger there: > > ======================================================================= > prod=# \d t_firma_moduller > Table > "public.t_firma_moduller" > Column | Type | > Modifiers > - ------------------+-----------------------------+-------------------------------------------------------------------------- > firma_no | character varying(10) | not null > modul_adi | character varying(20) | not null > last_update_date | timestamp without time zone | > last_update_user | character varying(45) | > kod | integer | not null default > fn_get_seq_value('t_firma_moduller'::character varying) > Indexes: > "t_firma_moduller_pkey" PRIMARY KEY, btree (firma_no, modul_adi) > "t_firma_moduller_kodu_ukey" UNIQUE, btree (kod) > Triggers: > "RI_ConstraintTrigger_39053" AFTER INSERT OR UPDATE ON > t_firma_moduller FROM t_firmalar NOT DEFERRABLE INITIALLY IMMEDIATE FOR > EACH ROW EXECUTE PROCEDURE > "RI_FKey_check_ins"('firma_moduller_firma_fkey1', 't_firma_moduller', > 't_firmalar', 'UNSPECIFIED', 'firma_no', 'no') Odd, why is this not showing up as a foreign key constraint? Has this database been upgraded (no matter through how many different upgrades) from an old version (7.1 or earlier I think)? > prod=# DROP TRIGGER RI_ConstraintTrigger_39053 ON t_firma_moduller; > ERROR: trigger "ri_constrainttrigger_39053" for table "t_firma_moduller" > does not exist You'd need to quote the trigger name because it's mixed case. > Is this a bug or something? There should not be a trigger there. Well, it really should be showing up as something like: CONSTRAINT firma_moduller_firma_fkey1 FOREIGN KEY (firma_no)REFERENCES t_firmalar(no)
pgsql-hackers by date: