From: Robert Haas Date: Sun, 3 Apr 2011 23:56:22 +0000 (-0400) Subject: Improve documentation on the range of the numeric data type. X-Git-Tag: REL9_1_BETA1~168 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=cabf5d84b6d1a92ab97492d7e3d650548a9992cd;p=postgresql Improve documentation on the range of the numeric data type. Gianni Ciolli, reviewed by Noah Misch --- diff --git a/doc/src/sgml/datatype.sgml b/doc/src/sgml/datatype.sgml index 0bb6594eab..ecc79e27fc 100644 --- a/doc/src/sgml/datatype.sgml +++ b/doc/src/sgml/datatype.sgml @@ -346,13 +346,13 @@ decimal variable user-specified precision, exact - no limit + up to 131072 digits before the decimal point; up to 16383 digits after the decimal point numeric variable user-specified precision, exact - no limit + up to 131072 digits before the decimal point; up to 16383 digits after the decimal point @@ -476,8 +476,8 @@ - The type numeric can store numbers with up to 1000 - digits of precision and perform calculations exactly. It is + The type numeric can store numbers with a + very large number of digits and perform calculations exactly. It is especially recommended for storing monetary amounts and other quantities where exactness is required. However, arithmetic on numeric values is very slow compared to the integer @@ -525,6 +525,15 @@ NUMERIC explicitly.) + + + The maximum allowed precision when explicitely specified in the + type declaration is 1000; otherwise the current implementation + of the NUMERIC is subject to the limits described + in . + + + If the scale of a value to be stored is greater than the declared scale of the column, the system will round the value to the specified