Changed By: HP
Change Date: February 11, 2010 04:28PM
PostgreSQL詨潸(Numeric Data Types)亥”
刻身摰 PostgreSQL 鞈摨急蝬撣豢典堆蝭甇方”嫣噶憭批振亥岷嚗
<TABLE BORDER="1" ><COL><COL><COL><COL><THEAD><TR><TH>Name</TH><TH>Storage Size</TH><TH>Description</TH><TH>Range</TH></TR></THEAD><TBODY><TR><TD><TT CLASS="TYPE">smallint</TT></TD><TD>2 bytes</TD><TD>small-range integer</TD><TD>-32768 to +32767</TD></TR><TR><TD><TT CLASS="TYPE">integer</TT></TD><TD>4 bytes</TD><TD>usual choice for integer</TD><TD>-2147483648 to +2147483647</TD></TR><TR><TD><TT CLASS="TYPE">bigint</TT></TD><TD>8 bytes</TD><TD>large-range integer</TD><TD>-9223372036854775808 to 9223372036854775807</TD></TR><TR><TD><TT CLASS="TYPE">decimal</TT></TD><TD>variable</TD><TD>user-specified precision, exact</TD><TD>no limit</TD></TR><TR><TD><TT CLASS="TYPE">numeric</TT></TD><TD>variable</TD><TD>user-specified precision, exact</TD><TD>no limit</TD></TR><TR><TD><TT CLASS="TYPE">real</TT></TD><TD>4 bytes</TD><TD>variable-precision, inexact</TD><TD>6 decimal digits precision</TD></TR><TR><TD><TT CLASS="TYPE">double precision</TT></TD><TD>8 bytes</TD><TD>variable-precision, inexact</TD><TD>15 decimal digits precision</TD></TR><TR><TD><TT CLASS="TYPE">serial</TT></TD><TD>4 bytes</TD><TD>autoincrementing integer</TD><TD>1 to 2147483647</TD></TR><TR><TD><TT CLASS="TYPE">bigserial</TT></TD><TD>8 bytes</TD><TD>large autoincrementing integer</TD><TD>1 to 9223372036854775807</TD></TR></TBODY></TABLE>
箸砌撣貊函 integer 憭批臬蝑蝝(billion)嚗bigint (big integer) 92 砍(鈭)
R><TH>Name</TH><TH>Storage Size</TH><TH>Description</TH><TH>Range</TH></TR></THEAD><TBODY><TR><TD><TT CLASS="TYPE">smallint</TT></TD><TD>2 bytes</TD><TD>small-range integer</TD><TD>-32768 to +32767</TD></TR><TR><TD><TT CLASS="TYPE">integer</TT></TD><TD>4 bytes</TD><TD>usual choice for integer</TD><TD>-2,147,483,648 to +2,147,483,647</TD></TR><TR><TD><TT CLASS="TYPE">bigint</TT></TD><TD>8 bytes</TD><TD>large-range integer</TD><TD>-9,223,372,036,854,775,808 to 9,223,372,036,854,775,807</TD></TR><TR><TD><TT CLASS="TYPE">decimal</TT></TD><TD>variable</TD><TD>user-specified precision, exact</TD><TD>no limit</TD></TR><TR><TD><TT CLASS="TYPE">numeric</TT></TD><TD>variable</TD><TD>user-specified precision, exact</TD><TD>no limit</TD></TR><TR><TD><TT CLASS="TYPE">real</TT></TD><TD>4 bytes</TD><TD>variable-precision, inexact</TD><TD>6 decimal digits precision</TD></TR><TR><TD><TT CLASS="TYPE">double precision</TT></TD><TD>8 bytes</TD><TD>variable-precision, inexact</TD><TD>15 decimal digits precision</TD></TR><TR><TD><TT CLASS="TYPE">serial</TT></TD><TD>4 bytes</TD><TD>autoincrementing integer</TD><TD>1 to 2147483647</TD></TR><TR><TD><TT CLASS="TYPE">bigserial</TT></TD><TD>8 bytes</TD><TD>large autoincrementing integer</TD><TD>1 to 9223372036854775807</TD></TR></TBODY></TABLE>
箸砌撣貊函 integer 憭批臬蝑蝝(2.1 billion)嚗bigint (big integer) 92 砍(鈭)
n)嚗bigint (big integer) 92 砍(鈭)
Reference:
http://www.postgresql.org/docs/8.3/static/datatype-numeric.html
Changed By: HP
Change Date: October 20, 2009 07:00PM
PostgreSQL詨潸(Numeric Data Type)亥”Types)亥”
刻身摰 PostgreSQL 鞈摨急蝬撣豢典堆蝭甇方”嫣噶憭批振亥岷嚗
Name | Storage Size | Description | Range |
---|
smallint | 2 bytes | small-range integer | -32768 to +32767 |
integer | 4 bytes | usual choice for integer | -2147483648 to +2147483647 |
bigint | 8 bytes | large-range integer | -9223372036854775808 to 9223372036854775807 |
decimal | variable | user-specified precision, exact | no limit |
numeric | variable | user-specified precision, exact | no limit |
real | 4 bytes | variable-precision, inexact | 6 decimal digits precision |
double precision | 8 bytes | variable-precision, inexact | 15 decimal digits precision |
serial | 4 bytes | autoincrementing integer | 1 to 2147483647 |
bigserial | 8 bytes | large autoincrementing integer | 1 to 9223372036854775807 |
箸砌撣貊函 integer 憭批臬蝑蝝(billion)嚗bigint (big integer) 92 砍(鈭)
n)嚗bigint (big integer) 92 砍(鈭)
Reference:
http://www.postgresql.org/docs/8.3/static/datatype-numeric.html
Original Message
雿: HP
Date: October 09, 2009 04:56PM
PostgreSQL詨潸(Numeric Data Type)亥”Types)亥”
刻身摰 PostgreSQL 鞈摨急蝬撣豢典堆蝭甇方”嫣噶憭批振亥岷嚗
Name | Storage Size | Description | Range |
---|
smallint | 2 bytes | small-range integer | -32768 to +32767 |
integer | 4 bytes | usual choice for integer | -2147483648 to +2147483647 |
bigint | 8 bytes | large-range integer | -9223372036854775808 to 9223372036854775807 |
decimal | variable | user-specified precision, exact | no limit |
numeric | variable | user-specified precision, exact | no limit |
real | 4 bytes | variable-precision, inexact | 6 decimal digits precision |
double precision | 8 bytes | variable-precision, inexact | 15 decimal digits precision |
serial | 4 bytes | autoincrementing integer | 1 to 2147483647 |
bigserial | 8 bytes | large autoincrementing integer | 1 to 9223372036854775807 |
箸砌撣貊函 integer 憭批臬蝑蝝(billion)嚗bigint (big integer) 92 砍(鈭)
n)嚗bigint (big integer) 92 砍(鈭)
Reference:
http://www.postgresql.org/docs/8.3/static/datatype-numeric.html