Is there a maximum length when storing into PostgreSQL TEXT

后端 未结 2 1016
时光取名叫无心
时光取名叫无心 2021-01-03 23:59

I have a sequence of string that vary a lot in length: from 30 to 282420 chars . I want to store each string into a postgres database using jdbc.

     Strin         


        
2条回答
  •  别那么骄傲
    2021-01-04 00:20

    According to the Postgres character type documentation, text is variable unlimited length.
    And further down:

    ... PostgreSQL provides the text type, which stores strings of any length.

    However

    According to the Postgres Wiki, there is a hard limit of 1GB for a single column value, so the practical limit for the "unlimited" length text value is limited to 1GB by the architecture.

提交回复
热议问题