Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitfd84caf

Browse files
committed
|I took a look at this and I think pg_dump mishandles arrays of ints and floats
|by neglecting to quote them.||I have made a minor change to pg_dump.c that will fix this.||Dates are dumped and restored OK with pg_dump in V6||We'll still need to fix the dump in both cases if the original dump is from V1.09.From Keith Parks
1 parente2292e0 commitfd84caf

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

‎src/bin/pg_dump/pg_dump.c

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
*
2121
*
2222
* IDENTIFICATION
23-
* $Header: /cvsroot/pgsql/src/bin/pg_dump/pg_dump.c,v 1.22 1997/01/0700:04:16 scrappy Exp $
23+
* $Header: /cvsroot/pgsql/src/bin/pg_dump/pg_dump.c,v 1.23 1997/02/09 03:00:09 scrappy Exp $
2424
*
2525
* Modifications - 6/10/96 - dave@bensoft.com - version 1.13.dhb
2626
*
@@ -284,12 +284,15 @@ dumpClasses_dumpData(FILE *fout, const char *classname,
284284
switch(PQftype(res,field)) {
285285
case21:case22:case23:/* int types */
286286
case810:case910:/* oldint types */
287-
case1005:case1006:case1007:/* _int types */
288287
case700:case701:/* float types */
289-
case1021:case1022:/* _float types */
290288
fprintf(fout,"%s",
291289
PQgetvalue(res,tuple,field));
292290
break;
291+
case1005:case1006:case1007:/* _int types */
292+
case1021:case1022:/* _float types */
293+
fprintf(fout,"'%s'",
294+
PQgetvalue(res,tuple,field));
295+
break;
293296
default: {
294297
char*expsrc,*expdest;
295298

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp