pgsql-formatting-10252004.patch
text/x-patch
Filename: pgsql-formatting-10252004.patch
Type: text/x-patch
Part: 0
Message:
Re: to_char/to_number loses sign
Patch
Same data as JSON:
GET /api/v1/attachments/:id/patch
the parsed metadata as JSON — format, series position, per-file stats; never the diff bytes.
API reference →
Format: unified
| File | + | − |
|---|---|---|
| src/backend/utils/adt/formatting.c | 3 | 2 |
--- pgsql/src/backend/utils/adt/formatting.c.num_s 2004-10-25 13:51:58.009789928 +0200
+++ pgsql/src/backend/utils/adt/formatting.c 2004-10-25 15:23:09.315025104 +0200
@@ -3625,7 +3625,7 @@
{
#ifdef DEBUG_TO_FROM_CHAR
- elog(DEBUG_elog_output, " --- scan start --- ");
+ elog(DEBUG_elog_output, " --- scan start --- >>%s<<", Np->number);
#endif
if (*Np->inout_p == ' ')
@@ -3642,7 +3642,7 @@
/*
* read sign
*/
- if (*Np->number == ' ' && (id == NUM_0 || id == NUM_9 || NUM_S))
+ if (*Np->number == ' ' && (id == NUM_0 || id == NUM_9 || id == NUM_S))
{
#ifdef DEBUG_TO_FROM_CHAR
@@ -4138,6 +4138,7 @@
case NUM_0:
case NUM_DEC:
case NUM_D:
+ case NUM_S:
if (Np->type == TO_CHAR)
{
NUM_numpart_to_char(Np, n->key->id);