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 vs varchar2

Re: char vs varchar2

From: <markp7832_at_my-deja.com>
Date: Mon, 20 Dec 1999 14:37:15 GMT
Message-ID: <83leur$v0f$1@nnrp1.deja.com>


In article <83lcn9$tba$1_at_nnrp1.deja.com>,   karsten_schmidt8891_at_my-deja.com wrote:
> Hi,
>
> char is a fixed-length datatype.
> if you have rows that need less than the max size you defined in the
> database, they will be right-padded with blanks.
> Varchar2 is a true varying lenght type - no padding.
>
> char is rarely used - in general you should use varchar2.
>
> Karsten
>
> In article <83kcr6$8lj$1_at_nnrp1.deja.com>,
> marcus_chan_at_my-deja.com wrote:
> > hello,
> >
> > hope someone could enlighten me on these?
> > 1. What are the diffrences between Char/varchar2?
> > 2. When should i use char/varchar2 in table creation?
> >
> > thanks
> > marcus
> >

I agree use varchar2. Look at Oracle's dictionary and Oracle products. They use varchar2 even for one byte columns.

--
Mark D. Powell -- The only advice that counts is the advice that  you follow so follow your own advice --

Sent via Deja.com http://www.deja.com/
Before you buy. Received on Mon Dec 20 1999 - 08:37:15 CST

Original text of this message

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