Re: Interval input: usec, msec
От | Neil Conway |
---|---|
Тема | Re: Interval input: usec, msec |
Дата | |
Msg-id | 1180415202.6648.65.camel@goldbach обсуждение исходный текст |
Ответ на | Re: Interval input: usec, msec (Neil Conway <neilc@samurai.com>) |
Ответы |
Re: Interval input: usec, msec
|
Список | 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
В списке pgsql-patches по дате отправления: