| From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
|---|---|
| To: | "mike" <matrix(at)quadrent(dot)net> |
| Cc: | pgsql-general(at)postgresql(dot)org, Philip Warner <pjw(at)rhyme(dot)com(dot)au> |
| Subject: | Re: pg_dump error |
| Date: | 2001-04-17 15:57:45 |
| Message-ID: | 23956.987523065@sss.pgh.pa.us |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-general |
"mike" <matrix(at)quadrent(dot)net> writes:
> dumpSequence(pilgram_en_id_seq): different sequence name returned by SELECT=
> : pilgram_cross_id_seq
> I'm not sure what this means, and I have no idea how to corect it.
Looking at the source code, it would seem that pg_dump is unhappy
because "SELECT sequence_name FROM pilgram_en_id_seq" returned
"pilgram_cross_id_seq" instead of the expected "pilgram_en_id_seq".
I'm not sure why exactly pg_dump is bothering to make such a
cross-check, but probably the more interesting question is how the
sequence got that way. Did you rename it at some point?
I find that "ALTER TABLE RENAME" will work without complaint on a
sequence. Seems we should either
(a) prohibit renaming a sequence;
(b) improve ALTER TABLE RENAME to know about changing the
sequence_name field as well;
(c) remove this cross-check from pg_dump; and/or
(d) remove the sequence_name field from sequences entirely.
(c) looks like the path of least resistance. I don't like (d) because
of the risk of breaking existing application code that might look at
the contents of sequences. Comments?
regards, tom lane
| From | Date | Subject | |
|---|---|---|---|
| Next Message | will trillich | 2001-04-17 16:01:41 | Re: bpchar type |
| Previous Message | Matthew | 2001-04-17 15:42:43 | RE: failed sanity check, table answers was not found |