Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Varchar2 size?

724687Jan 6 2010 — edited Jan 6 2010
I read that oversizing a varchar2 column in a table doesn't affect storage space, but does effect query performance. I was wondering if there were some "rules" to determine the perfect varchar2 size od a column? Let me clarify myself:

I need a varchar2 column to store a zipcode. Normally these codes are 4 characters. So for best performances I should define it as varchar2(4). But if it is so that performance would be exactly the same when i define it as a varchar2(10), I'd better define it that way in case there should be a change in zipcode structures over here, no?

So what I'd like to know: are there rules (block-sizes, tablespace things, I don't know...) to take into consideration before determining the ideal size of a varchar2?
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Feb 3 2010
Added on Jan 6 2010
10 comments
3,381 views