Re: [HACKERS] NUMERIC and Perl - Mailing list pgsql-hackers

From jwieck@debis.com (Jan Wieck)
Subject Re: [HACKERS] NUMERIC and Perl
Date
Msg-id m10IH8n-000EBQC@orion.SAPserv.Hamburg.dsh.de
Whole thread Raw
In response to Re: [HACKERS] NUMERIC and Perl  (Kaare Rasmussen <kar@webline.dk>)
List pgsql-hackers
>
> > Looks like not, unless I'm forgetting a feature...
>
> That's why I asked. So I hope it will be compatible with Perl's
> Math-BigInteger module.

    NUMERIC isn't INTEGER data!

    Well  -  you can define an attribute as NUMERIC(33,0) and all
    values assigned to that column will be rounded to the closest
    integer   (an   integer  that  can  hold  values  up  to  999
    quintillions exactly).  But as soon as  you  do  calculations
    with  other  values that have fractions, there will a decimal
    point and digits after that appear in the result. Don't  know
    how  Perl  might  respond to it.  Maybe you need to round the
    result explicitly on calculations.


Jan

--

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

pgsql-hackers by date:

Previous
From: Kaare Rasmussen
Date:
Subject: Re: [HACKERS] NUMERIC and Perl
Next
From: Michael Davis
Date:
Subject: parser enhancement request for 6.5