科学符号存储Postgres [英] Scientific Notation storage Postgres
问题描述
我正在使用postgres 9.5,并且试图弄清楚如何以长或科学记数格式存储数据。例如,在excel中,我有一个 42540528726795050063891204319802818560
,在该列中显示为 4.2540768075074E + 37
。如何在Postgres中正确存储此数字,以便可以将其查询为数字,对其进行排序,对其进行计算等?
I am using postgres 9.5, and I am trying to figure out how to store data in the "long" or "scientific notation" format. For example, in excel, I have a number 42540528726795050063891204319802818560
, which shows up as 4.2540768075074E+37
in the column. How do I properly store this number in Postgres so that I can query it as a number, sort it, perform calculations on it, etc?
推荐答案
在下面的链接中查看所需的文档。
Check this below link for the required documentation.
< a href = https://www.postgresql.org/docs/9.5/static/datatype-numeric.html rel = nofollow> https://www.postgresql.org/docs/9.5/static/datatype- numeric.html
NUMERIC数据类型可以接受小数点前位数为131072位的整数。
NUMERIC datatype can accept an integer with digit length upto 131072 digits before the decimal point.
这篇关于科学符号存储Postgres的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!