Re: WIP: to_char, support for EEEE format

From: Brendan Jurd <direvus(at)gmail(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Euler Taveira de Oliveira <euler(at)timbira(dot)com>, Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>, Robert Haas <robertmhaas(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: WIP: to_char, support for EEEE format
Date: 2009-08-04 03:39:54
Message-ID: 37ed240d0908032039u19354e01qe3841c29e8dcdd4a@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

2009/8/4 Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>:
> BTW, there's no rule saying you have to fix that strictly within
> to_char().  It might make more sense to have numeric.c export a
> function that is like numeric_out but produces e-style output.
> Your choice as the patch writer, but keep it in mind ...
>

Ah, thanks for the suggestion. I think you're right, numeric.c would
be a nice place for this code. Going directly from the guts of a
NumericVar to a scientific notation seems more elegant than performing
cut-and-paste style surgery on the string from numeric_out().

It does require a bit more effort and headspace than I was expecting.
I'm still keen to do it, but my "next day or so" timeframe may not be
so realistic. It's looking more like "by the end of the week".

Cheers,
BJ

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message David Fetter 2009-08-04 03:47:24 Re: SE-PostgreSQL Specifications
Previous Message Tao Ma 2009-08-04 03:34:54 Re: question about the _SPI_save_plan() and plan cache