Re: getXXX methods

From: Oliver Jowett <oliver(at)opencloud(dot)com>
To: Kris Jurka <books(at)ejurka(dot)com>
Cc: pg(at)fastcrypt(dot)com, "pgsql-jdbc(at)postgresql(dot)org" <pgsql-jdbc(at)postgresql(dot)org>
Subject: Re: getXXX methods
Date: 2004-07-07 01:48:51
Message-ID: 40EB5683.90301@opencloud.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

Kris Jurka wrote:

> The
> DataTruncation API is organized around byte sizes and just doesn't seem
> right for numeric data.

There is support throughout that API for "unknown sizes" which seems
appropriate when you're not dealing with explicitly-sized types. And
even types such as varchar don't map directly to bytes anyway..

> Even if the spec does imply that a warning
> shuold be issued (which is not clear to me), I can't imagine why
> anyone would want this. If I want truncation I'll do it myself, otherwise
> I want any error to immediately raise a red flag and put the brakes on
> processing.

I tend to agree -- but Dave evidently has a use for it, in which case
truncation+warning seems a lesser evil than silent truncation.

> How many people really check for warnings anyway?

I hate this argument. If we don't generate any warnings, of course no
one will check for them!

-O

In response to

Responses

Browse pgsql-jdbc by date

  From Date Subject
Next Message Kris Jurka 2004-07-07 01:58:19 Re: getXXX methods
Previous Message Kris Jurka 2004-07-07 01:38:52 Re: getXXX methods