Re: FK -> non PK - bad design?

From: Mike <Star.Point_at_mcsci.net>
Date: 11 Apr 2003 12:04:35 -0700
Message-ID: <a90c0da6.0304111104.78e44a7c_at_posting.google.com>


71062.1056_at_compuserve.com (--CELKO--) wrote in message news:<c0d87ec0.0304110613.34c01ae1_at_posting.google.com>...
> >> Is it really worth adding an 'S' to every table name in the world
> just to remind ourselves that there is more than one record [sic] in
> it? <<
>
> Yes, but what you really want is often a collective noun or other name
> that tells the reader this is a set. Example: Employee = bad;
> Employees = better; Personnel = good.
>

What a crock! Naming a table with a plural is just personal preference! It's not "good" or "bad". ISO 11179 says nothing of using plurals.

Here is good reason NOT to use plural table names: When you write code to use a SQL DBMS (and other things) it is very advantages to build templates with a text place-holder for the table name and other programmatic object names (and other things). Then when you use the templates and do a text find/replace on the place-holder name you don't end up with oddly named plural objects. Don't use the plural "s" or "es" or whatever because is it "good", use it only if it does something to make work easier!

> >> If so, should we pluralise all the column names too for the same
> reason - e.g. there are many employee names in the "employee_name"
> column? :) <<
>
> No, because the values of a COLUMN (not a "record" -- totally
> different concept!) are scalars. Saying "employee_names" would mean
> that you have crowded several names in one column, in violation of
> First Normal Form.

Sorry --CELKO--, in the real world sometimes there are several things crowded into one column! I know this blows your personal preference for plurals but such is life... Received on Fri Apr 11 2003 - 21:04:35 CEST

Original text of this message