From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Kev <kevinjamesfield(at)gmail(dot)com> |
Cc: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: varchar(n) VS text |
Date: | 2007-06-30 00:09:58 |
Message-ID: | 10066.1183162198@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Kev <kevinjamesfield(at)gmail(dot)com> writes:
> On Jun 26, 12:16 am, t(dot)(dot)(dot)(at)sss(dot)pgh(dot)pa(dot)us (Tom Lane) wrote:
>> "Pierre Thibaudeau" <pierd(dot)(dot)(dot)(at)gmail(dot)com> writes:
>>> I am puzzling over this issue:
>>> 1) Is there ever ANY reason to prefer "varchar(n)" to "text" as a column type?
>>
>> In words of one syllable: no.
> If you have any input from untrusted sources (like in a web app)
> wouldn't it be easier to attack the server if you had a text field,
> like by sending a couple TB of data over that pgsql then needs to
> store, on a server that doesn't have that amount of space?
Well, the hard limit on a text field (or any other field) is 1Gb,
so it'd not be quite as easy as that, even assuming that the webapp
doesn't fall over first.
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Jan de Visser | 2007-06-30 00:26:54 | Re: Looking for help regarding getting the latest inserted sequence value. |
Previous Message | Bruno Wolff III | 2007-06-29 22:41:35 | greatest/least semantics different between oracle and postgres |