Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: char versus varchar datatype

Re: char versus varchar datatype

From: Mike Burden <michael.burden_at_capgemini.co.uk>
Date: Wed, 17 Feb 1999 09:38:30 +0000
Message-ID: <36CA8E15.AF540BF8@capgemini.co.uk>


I may be wrong here but I believe that Oracle uses a length field even for CHAR data types. Internally there are only varying character strings. This means all Oracle needs to do is pad a CHAR field and it can then use it's underlying varchar data type.

As for which one to use, well I have had big arguments over this. I tend to favour varchar2 as it's more flexible and efficient.

Frank Leenders wrote:

> Hello all,
> this question probably has been asked before, but I missed the answer.
> What arguments are there for the choice between a CHAR field in a table and
> a VARCHAR datatype?
> Of course, varchar has a variable length and that means less used space. On
> the other hand a length byte is added and maybe it takes more time to find
> the correct column in a block when all fields have a variable length. Or
> .......?
> Thanx
> Frank
Received on Wed Feb 17 1999 - 03:38:30 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US