From: | Neil Conway <neilc(at)samurai(dot)com> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | pgsql-patches(at)postgresql(dot)org |
Subject: | Re: Interval input: usec, msec |
Date: | 2007-05-29 05:06:42 |
Message-ID: | 1180415202.6648.65.camel@goldbach |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-patches |
On Mon, 2007-28-05 at 13:54 -0400, Neil Conway wrote:
> Okay, attached is a patch that does this. To summarize, the changes are:
>
> * add tmask bits for msec, usec (I reordered the #defines to keep
> them logically contiguous, but AFAICS this isn't necessary)
> * if the user specifies multiple instances of usec, msec, or sec,
> reject as invalid input
> * if the user specifies a fractional second ("5.5 seconds"), also
> consider that to be millisecond and microsecond input from the
> POV of rejecting duplicate units. So "5.5 seconds 1 millisecond"
> will be rejected.
Applied to HEAD, backported to 8.2 and 8.1
After I applied the patches, it occurred to me that this patch actually
slightly changes previous behavior: the previous coding accepted inputs
like "1 microsecond 1 microsecond 1 second", whereas the patch rejects
this input. I don't think this is a major problem (input of this kind is
likely a client bug), but I figured I'd mention it...
-Neil
From | Date | Subject | |
---|---|---|---|
Next Message | Les Hill | 2007-05-29 12:31:58 | OS X startup script patch |
Previous Message | Tom Lane | 2007-05-29 03:07:42 | Re: Interval input: usec, msec |