Re: 3NF question

From: Alan <alan_at_erols.com>
Date: Thu, 13 Jan 2005 09:50:55 -0500
Message-ID: <34ng6cF4dol5fU1_at_individual.net>


"-CELKO-" <jcelko212_at_earthlink.net> wrote in message news:1105574148.725975.63860_at_c13g2000cwb.googlegroups.com...
> >> I'm not sure what the answer is to the whole naming question, but
> can't the column name "id" be interpreted in the context of the name of
> the table in which it appears? <<
>
> The context it appears in is the whole schema, not a table. You do
> have a data dictionary, don't you? And it applies to the whole data
> model, right? You are confusing Cobol file declarations with RDBMS
> table declarations.
>
> If an "employee_salary" is logical different from other salaries,then
> it needs that name. It is not, then you might have "salary_amt" ,
> "salary_grade", etc. that give the attributes of that entity in your
> model.
>

But what happens when your needs expand, and you now need to identify different kinds of salaries (which is a bad example, but is still valid)? Sure, it's easy enough to go back and modify the column names of existing columns in the database, but how about all the applications and code written using the old column names?

> The rule for identifiers is:
> 1) Use the industry standard if you have one
> 2) Look for a natural key if you have one
> 3) carefully define your own key (check digits, vlaidation rules, etc.)
> only if you must.
>
Received on Thu Jan 13 2005 - 15:50:55 CET

Original text of this message