Group: pgsql.admin


Subject: Legacy foreign keys
From: tgl@sss.pgh.pa.us (Tom Lane)
Date: 12/10/2007 5:08:12 PM
Alvaro Herrera <alvherre@alvh.no-ip.org> writes: > Peter Koczan escribió: >> I am having a problem with what appear to be legacy foreign keys in >> some of my databases (probably pre-7.2 days). They won't restore from >> 8.2 to 8.3, because the '<unnamed>' field in the called function isn't >> unique when I try to restore more than one of these legacy keys > 8.3's pg_dump contains smarts to dump these things as normal FKs. Try > it. No, pg_dump isn't involved --- the new smarts are inside the server, in CREATE CONSTRAINT TRIGGER. It sounds like Peter has a case that is confusing that new code. Could we see a complete example? regards, tom lane ---------------------------(end of broadcast)--------------------------- TIP 9: In versions below 8.0, the planner will ignore your desire to choose an index scan if your joining column's datatypes do not match

Subject: Legacy foreign keys
From: tgl@sss.pgh.pa.us (Tom Lane)
Date: 12/10/2007 10:59:06 PM
"Peter Koczan" <pjkoczan@gmail.com> writes: > I am having a problem with what appear to be legacy foreign keys in > some of my databases (probably pre-7.2 days). They won't restore from > 8.2 to 8.3, because the '<unnamed>' field in the called function isn't > unique when I try to restore more than one of these legacy keys BTW, I spent some time trying to reproduce that, without success; so I'm now even more interested in seeing your example case. I think your "because" diagnosis is probably wrong ... regards, tom lane ---------------------------(end of broadcast)--------------------------- TIP 4: Have you searched our list archives? http://archives.postgresql.org

Subject: Legacy foreign keys
From: tgl@sss.pgh.pa.us (Tom Lane)
Date: 12/11/2007 10:06:10 PM
"Peter Koczan" <pjkoczan@gmail.com> writes: >> No, pg_dump isn't involved --- the new smarts are inside the server, >> in CREATE CONSTRAINT TRIGGER. It sounds like Peter has a case that is >> confusing that new code. Could we see a complete example? > Sure, here's the command: [ squint... ] Which 8.3beta are you testing, exactly? This was dealt with in beta3. If it is beta3 or later, please send the output of "pg_dump -s -t wspolicy" from the 8.2 database. regards, tom lane ---------------------------(end of broadcast)--------------------------- TIP 7: You can help support the PostgreSQL project by donating at http://www.postgresql.org/about/donate