Re: Libpq support for precision and scale

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Fernando Nasser <fnasser(at)redhat(dot)com>, Fernando Nasser <fnasser(at)cygnus(dot)com>, pgsql-hackers(at)postgresql(dot)org, Liam Stewart <liams(at)cygnus(dot)com>
Subject: Re: Libpq support for precision and scale
Date: 2002-03-08 01:57:24
Message-ID: 200203080157.g281vO903977@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Tom Lane wrote:
> BTW, I also had a bunch of concerns having to do with odd-seeming
> choices about what information would be wired into libpq and what
> would be retrieved at runtime from the backend. I don't recall the
> details at the moment, but I want to raise a flag that that is still
> an issue for me. I'd like to see some explicit design decisions
> about what information will be treated in which way.

I noticed that too, and looked into it. I didn't see any hard-wired
oids (at least that I remember), but I did see cases where the
scale/precision results had to be accessed based on the specific type
involved, e.g. NUMERIC. I don't see a way around this, and in fact most
people are doing this type-speicific stuff in their apps. The only
other solution I can see is adding a backend function that does these
type-specific manipulations and returns them to the client. This seems
quite attractive, especially considering changes in internal type
representations between releases.

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 853-3000
+ If your life is a hard drive, | 830 Blythe Avenue
+ Christ can be your backup. | Drexel Hill, Pennsylvania 19026

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Tatsuo Ishii 2002-03-08 02:00:33 Re: point in time recovery and moving datafiles online
Previous Message Tom Lane 2002-03-08 01:53:47 Re: Libpq support for precision and scale