Re: Which one should I use: varchar() or char()?

From: Palooka <>
Date: Sun, 04 Oct 2009 16:06:46 +0100
Message-ID: <aS2ym.261700$LX3.77767_at_newsfe17.ams2>

On 04/10/09 13:53, Ramon F Herrera wrote:
> I inherited a bunch of database tables and just noticed that for
> historical reasons, one of the important tables has records based on
> varchar(), and the other on char().
> Note: I have never been able to come to grips with PL/SQL and
> essentially all my database access (except for table creation and
> table loading) is done through Pro*C/C++.
> What are the trade-offs between char() and varchar()? Which one should
> I use?

Use varchar2 unless you have a very good reason not to. A char is just a varchar2 padded with spaces.

Palooka Received on Sun Oct 04 2009 - 10:06:46 CDT

Original text of this message