diff options
author | Marc G. Fournier <scrappy@hub.org> | 1997-02-09 03:00:09 +0000 |
---|---|---|
committer | Marc G. Fournier <scrappy@hub.org> | 1997-02-09 03:00:09 +0000 |
commit | fd84cafb696326326397004d34fbbc650daf8f82 (patch) | |
tree | 52e498df566e262870a11727debff04b005f4cd2 | |
parent | e2292e0c0cdd10c3b81995e1b1aee4d16e109c48 (diff) | |
download | postgresql-fd84cafb696326326397004d34fbbc650daf8f82.tar.gz postgresql-fd84cafb696326326397004d34fbbc650daf8f82.zip |
|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
-rw-r--r-- | src/bin/pg_dump/pg_dump.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/bin/pg_dump/pg_dump.c b/src/bin/pg_dump/pg_dump.c index 47706dac169..52f8baa4b75 100644 --- a/src/bin/pg_dump/pg_dump.c +++ b/src/bin/pg_dump/pg_dump.c @@ -20,7 +20,7 @@ * * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/bin/pg_dump/pg_dump.c,v 1.22 1997/01/07 00:04:16 scrappy Exp $ + * $Header: /cvsroot/pgsql/src/bin/pg_dump/pg_dump.c,v 1.23 1997/02/09 03:00:09 scrappy Exp $ * * Modifications - 6/10/96 - dave@bensoft.com - version 1.13.dhb * @@ -284,12 +284,15 @@ dumpClasses_dumpData(FILE *fout, const char *classname, switch(PQftype(res,field)) { case 21: case 22: case 23: /* int types */ case 810: case 910: /* oldint types */ - case 1005: case 1006: case 1007: /* _int types */ case 700: case 701: /* float types */ - case 1021: case 1022: /* _float types */ fprintf(fout, "%s", PQgetvalue(res,tuple,field)); break; + case 1005: case 1006: case 1007: /* _int types */ + case 1021: case 1022: /* _float types */ + fprintf(fout, "'%s'", + PQgetvalue(res,tuple,field)); + break; default: { char *expsrc,*expdest; |