>Jim Nasby <[EMAIL PROTECTED]> wrote on 02/08/2007 12:12:00 PM:
> Also, I suggest using "char" instead of just char. "char" is a 
> special data type that's limited to storing a single character; the 
> advantage is that it's much smaller and faster than a char.
> 
> If you do end up back at using foreign keys, I suggest using either a 
> smallint or "char"... the savings across the number of fields you're 
> looking at would start to add up, especially if you start putting a 
> decent number of rows in the table.
> --
> Jim Nasby                                            [EMAIL PROTECTED]
> EnterpriseDB      http://enterprisedb.com      512.569.9461 (cell)

Hi Jim,

I ended up using Varchar(1). According to the help there is no speed 
difference in the character types, on am I misunderstanding something? 

Tip: There are no performance differences between these three types, apart 
from the increased storage size when using the blank-padded type. While 
character(n) has performance advantages in some other database systems, it 
has no such advantages in PostgreSQL. In most situations text or character 
varying should be used instead. 
from: http://www.postgresql.org/docs/8.2/static/datatype-character.html

Margaret Gillon 

Reply via email to