Re: [HACKERS] Money type display

From: darcy(at)druid(dot)net (D'Arcy J(dot)M(dot) Cain)
To: martin(at)biochemistry(dot)ucl(dot)ac(dot)uk
Cc: hackers(at)postgreSQL(dot)org
Subject: Re: [HACKERS] Money type display
Date: 1998-02-27 16:32:53
Message-ID: m0y8SiT-00000oC@druid.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Thus spake Andrew Martin
> > I wonder if I didn't make a mistake in the money type. As a C library
> > function it made sense to add the "$" to the display because it was
> > easy to add one to the return value if it wasn't required. I'm finding
> > it to be a bit of a problem with my Python interface. I was just
> > going to strip it in my module but I thought I would see if others
> > felt that it should simply be dropped from the PostgreSQL output.
> >
> Remove it! Those of us who aren't American/Canadian/Australian don't want
> a dollar sign for money anyway :-)

Right. The original code that that comes from used locale extensively
for things like that.

Also, what about the commas? Again, locale is supposed to be used to
determine which character to use but I am sure it just causes confusion.

In fact, perhaps we should just turn the money code into the decimal
type. I understand we have a mechanism now for specifying an argument
to the input and output functions so we can specify the precision of
the decimal. Is this correct? If someone can help me out with the
type specifications, I'll start creating the code to handle decimal
types. I'll just take the money code and modify it.

--
D'Arcy J.M. Cain <darcy(at){druid|vex}.net> | Democracy is three wolves
http://www.druid.net/darcy/ | and a sheep voting on
+1 416 424 2871 (DoD#0082) (eNTP) | what's for dinner.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message The Hermit Hacker 1998-02-27 16:45:42 Re: [HACKERS] Odd behavior of initdb
Previous Message Integration 1998-02-27 16:25:28 Odd behavior of initdb