Re: Regarding varchar max length in postgres

From: Thomas Kellerer <spam_eater(at)gmx(dot)net>
To: pgsql-general(at)lists(dot)postgresql(dot)org
Subject: Re: Regarding varchar max length in postgres
Date: 2018-10-15 09:40:42
Message-ID: 584855e4-cd0a-0036-611a-81f088cb40c3@gmx.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Durgamahesh Manne schrieb am 15.10.2018 um 11:18:
> was there any specific reason that you have given max length for varchar is limited to 10485760 value?
>
> why you have not given max length for varchar is unlimited like text datatype ?
>
> |character varying(/|n|/)|, |varchar(/|n|/)|variable-length with limit 
> |character(/|n|/)|, |char(/|n|/)|fixed-length, blank padded
> |text|variable unlimited length

It "text" type is a "character string" just like all the other character types and thus is also limited to 1GB

"text", "varchar", "character varying" and "character" are all identical in how they are stored and processed.

Thomas

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Joshua White 2018-10-15 09:46:38 Problem creating a database
Previous Message Laurenz Albe 2018-10-15 09:40:31 Re: Regarding varchar max length in postgres