Skip site navigation (1) Skip section navigation (2)

Re: Fixes for MONEY type using locale

From: Bruce Momjian <bruce(at)momjian(dot)us>
To: Bruce Momjian <bruce(at)momjian(dot)us>
Cc: darcy(at)druid(dot)net, PostgreSQL-patches <pgsql-patches(at)postgresql(dot)org>
Subject: Re: Fixes for MONEY type using locale
Date: 2007-11-24 15:28:54
Message-ID: 200711241528.lAOFSs507263@momjian.us (view raw or flat)
Thread:
Lists: pgsql-hackerspgsql-patches
Patch applied.  I will email on this LAST_DIGIT issue separately.

---------------------------------------------------------------------------

Bruce Momjian wrote:
> In looking at the use of the thousands separator in formatting.c and
> psql/print.c, I now see similar problems with the MONEY type, namely
> that if the thousands separator is "" it is set to "," even if the
> decimal separator is ",".
> 
> The attached patch fixes this.
> 
> I also removed a ssymbol test because ssymbol will never be \0 based on
> the code.  Also, what does this do:
> 
> 	if (buf[LAST_DIGIT] == ',')
> 		buf[LAST_DIGIT] = buf[LAST_PAREN];
> 
> -- 
>   Bruce Momjian  <bruce(at)momjian(dot)us>        http://momjian.us
>   EnterpriseDB                             http://postgres.enterprisedb.com
> 
>   + If your life is a hard drive, Christ can be your backup. +


> 
> ---------------------------(end of broadcast)---------------------------
> TIP 9: In versions below 8.0, the planner will ignore your desire to
>        choose an index scan if your joining column's datatypes do not
>        match

-- 
  Bruce Momjian  <bruce(at)momjian(dot)us>        http://momjian.us
  EnterpriseDB                             http://postgres.enterprisedb.com

  + If your life is a hard drive, Christ can be your backup. +

In response to

pgsql-hackers by date

Next:From: Gregory StarkDate: 2007-11-24 16:16:27
Subject: Re: 8.3devel slower than 8.2 under read-only load
Previous:From: D'Arcy J.M. CainDate: 2007-11-24 14:24:41
Subject: Re: Fixes for MONEY type using locale

pgsql-patches by date

Next:From: Bruce MomjianDate: 2007-11-24 16:27:38
Subject: Re: Fixes for MONEY type using locale
Previous:From: D'Arcy J.M. CainDate: 2007-11-24 14:24:41
Subject: Re: Fixes for MONEY type using locale

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group