| From: | "Bort, Paul" <pbort(at)tmwsystems(dot)com> | 
|---|---|
| To: | "pgsql-hackers" <pgsql-hackers(at)postgresql(dot)org> | 
| Subject: | Re: Reducing data type space usage | 
| Date: | 2006-09-16 04:52:35 | 
| Message-ID: | DB106B1B5B8F734B8FF3E155A3A556C202D4FFC5@clemail1.tmwsystems.com | 
| Views: | Whole Thread | Raw Message | Download mbox | Resend email | 
| Thread: | |
| Lists: | pgsql-hackers | 
Gregory Stark writes:
> Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> writes:
> >
> > There isn't if you want the type to also handle long strings.
> > But what if we restrict it to short strings?  See my 
> message just now.
> 
> Then it seems like it imposes a pretty hefty burden on the user. 
> 
But there are a lot of places where it wins: 
- single byte for a multi-state flag
- hex representation of a hash (like SHA-1)
- part numbers
- lots of fields imported from legacy systems
- ZIP/Postal codes
And for all of those you can decisively say at design time that 127
characters is an OK limit.
+1 for Bruce/Tom's idea.
Regards,
Paul Bort
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Nicolas Barbier | 2006-09-16 09:34:25 | Re: Optimize ORDER BY ... LIMIT | 
| Previous Message | Gregory Stark | 2006-09-16 04:01:12 | Re: The enormous s->childXids problem |