mirror of
https://github.com/postgres/postgres.git
synced 2025-08-12 15:23:02 +03:00
Backpatch into 6.5.*.
One last missing quoting bug in pg_dump: now that sequence names are properly quoted for field defaults, mixed case sequence names are generated. These are properly quoted in the CREATE SEQUENCE lines, but not in the SELECT nextval lines, as per below: CREATE SEQUENCE "Teams_TeamID_seq" start 10 increment 1 maxvalue 2147483647 minvalue 1 cache 1 ; SELECT nextval ('Teams_TeamID_seq'); This needs to be: SELECT nextval ('"Teams_TeamID_seq"'); Patch included below. -- Ross J. Reedstrom, Ph.D., <reedstrm@rice.edu>
This commit is contained in:
@@ -21,7 +21,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/bin/pg_dump/pg_dump.c,v 1.115.2.1 1999/09/01 23:06:26 momjian Exp $
|
||||
* $Header: /cvsroot/pgsql/src/bin/pg_dump/pg_dump.c,v 1.115.2.2 1999/09/23 19:13:49 momjian Exp $
|
||||
*
|
||||
* Modifications - 6/10/96 - dave@bensoft.com - version 1.13.dhb
|
||||
*
|
||||
@@ -3193,7 +3193,7 @@ dumpSequence(FILE *fout, TableInfo tbinfo)
|
||||
if (called == 'f')
|
||||
return; /* nothing to do more */
|
||||
|
||||
sprintf(query, "SELECT nextval ('%s');\n", tbinfo.relname);
|
||||
sprintf(query, "SELECT nextval ('%s');\n", fmtId(tbinfo.relname, force_quotes));
|
||||
fputs(query, fout);
|
||||
|
||||
}
|
||||
|
@@ -3,7 +3,7 @@
|
||||
* procedural language
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/pl/plpgsql/src/pl_comp.c,v 1.7.2.1 1999/09/20 21:47:21 momjian Exp $
|
||||
* $Header: /cvsroot/pgsql/src/pl/plpgsql/src/pl_comp.c,v 1.7.2.2 1999/09/23 19:13:55 momjian Exp $
|
||||
*
|
||||
* This software is copyrighted by Jan Wieck - Hamburg.
|
||||
*
|
||||
|
Reference in New Issue
Block a user