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

Home -> Community -> Mailing Lists -> Oracle-L -> RE: Primary key type selection

RE: Primary key type selection

From: Jain, Akshay <Akshay.Jain_at_cit.com>
Date: Tue, 16 May 2000 10:37:33 -0400
Message-Id: <10499.105743@fatcity.com>


This seems to be related to my post of VARCHAR2 vs. CHAR, to which I have no direct responses.

My concern is towards both performance and a tighter data model. If primary keys
(foreign keys in other tables) are allowed to vary in length, then the comparison at
search time becomes looser and therefore must take longer, or at best be no better ever.
It also allows for more error in the human interaction ('0270' is same as '00270', '0270 ', etc.).

It seems that numbers are most severely restricted in the variety of entries possible,
followed by CHAR, followed by VARCHAR2. This is the order of my personal preference
for primary keys.

Akshay Jain



Newcourt-CIT
Tel. (416) 507-5385
mailto:Akshay.Jain_at_cit.com
Received on Tue May 16 2000 - 09:37:33 CDT

Original text of this message

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