Re: [HACKERS] Re: [PATCHES] ':' and ';' operators - Mailing list pgsql-hackers

From wieck@debis.com (Jan Wieck)
Subject Re: [HACKERS] Re: [PATCHES] ':' and ';' operators
Date
Msg-id m11r1MH-0003kGC@orion.SAPserv.Hamburg.dsh.de
Whole thread Raw
In response to Re: [PATCHES] ':' and ';' operators  (Peter Eisentraut <e99re41@DoCS.UU.SE>)
List pgsql-hackers
Peter Eisentraut wrote:

> All of these functions should be overloaded for float4, float8, and
> numeric, as well as int* where appropriate. Some might argue that things
> such as sin() or exp() do not make sense for numeric and you should cast
> it to float. I'm not sure myself.

    They  make sense for numeric, because you can get the sine of
    a value with hundreds of SIGNIFICANT digits. Would be  damned
    slow, but if needed...

    NUMERIC  has  a  higher  precision  than  float8. The problem
    arising at this point is to ensure that  an  expression  with
    mixed  attribute  types (numeric, floatN and/or integer) must
    allways cast anything to numeric  if  at  least  one  of  the
    arguments is.

    The  trigonometric  functions  are  missing for numeric up to
    now, but there are Taylor and McLaurin definitions available.


Jan

--

#======================================================================#
# It's easier to get forgiveness for being wrong than for being right. #
# Let's break this rule - forgive me.                                  #
#========================================= wieck@debis.com (Jan Wieck) #

pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: [HACKERS] pid file for postmaster?
Next
From: Tim Holloway
Date:
Subject: Re: [HACKERS] pid file for postmaster?