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: Naming Convention for Columns

Re: Naming Convention for Columns

From: <adelamerens_at_fisi-madison.com>
Date: 1998/03/06
Message-ID: <6dov9f$ivn$1@nnrp1.dejanews.com>#1/1

In article <6dnbes$6r5_at_newsops.execpc.com>,   dave.mullen_at_emjay.com (Dave Mullen) wrote:
>
> Hello all,
>
> We are setting up new database naming conventions, and I'd like to
> hear other people's thoughts on what they consider to be important
> considerations.
>
> In particular, I'd like to know how people feel about prefixing the
> names of columns in a relational data base with a short prefix
> representing the table to which the column belongs. (Foreign keys
> would retain the prefix of the foreign table, [clip]

Dave,

It is very helpful to a developer (and anyone else that must refer to the items) to have standardized nomenclature for all data references. With respect to column naming conventions, prefixing the column name with an abbreviated table reference is precisely the way I have always approached this issue. Even foreign keys follow the rule... For example

Customer Master Table           Customer Detail Table
cm_key                          cd_key
cm_acctno                       cd_cmkey  (foreign key to Customer Master)

With long column names and plethora of tables, the problem is trying to keep the prefixes short enough not to be intrusive but long enough to be descriptive.

A well-contrived nomenclature standard allows for a cleaner appearance when coding, obviates the need to use table names for the qualification of columns (i.e. eliminates redundance) [although some would argue, with validity, that all columns be fully qualified...] and is much easier for developers to remember without constant reference to table structures, etc...

Well now, that should open a big ole can o' worms!!

Just my $0.02... HTH

-----== Posted via Deja News, The Leader in Internet Discussion ==----- http://www.dejanews.com/ Now offering spam-free web-based newsreading Received on Fri Mar 06 1998 - 00:00:00 CST

Original text of this message

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