Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Mailing Lists -> Oracle-L -> RE: Table Naming Conventions
I ran into a problem with this once. I had a procedure that I used to
monitor database statistics that I named monitor_stats. I stored that
data in a table called monitor_stats (OK, I should have named the table
stats, but that seemed too generic). With a procedure and table named
the same, the procedure wouldn't compile. When I renamed the procedure
to monitor_stats_proc, it worked.
But I agree that keeping object types out of their names is a good idea.
dba_Stephen
Stephen_dba
Stephen
>>> cary.millsap_at_hotsos.com 07/30/02 03:53PM >>>
I just think it's a waste. You can tell by context what kind of thing
a
thing is. For example, consider: "select a.flarg from bloing a where
a.croopoo > 7". This can be understood by syntactical context (even
with
the nonsense names), without having to rename "bloing" to
"bloing_table".
Most of the embedding of type names into object names that I've seen
has
been implemented by users who were inexperienced at the time they
created the standard. They were worried that without embedding the
type
name into the object name, they might forget what kind of object it
was.
...Most such naming conventions become onerous over time, long after
you
find out that you can find the type of something in the data
dictionary,
but after it's too late to save the thousands of extra characters of
typing that'll waste people's lifespans over time.
In my old OFA paper, I made a joke about how we don't embed type names
into object names in daily life, with just a few exceptions (Billy the
Kid, Winnie the Pooh, Atilla the Hun, and the younger family members
of
the old Walton Family TV show are a few examples). If you have both a
dog and a child named "Rex," though, it's probably a good idea to
expect
them both to come when you call. With SQL, though, I can't think of a
case in which it's not easy to tell by syntactic context what kind of
thing you're talking about...
Cary Millsap
Hotsos Enterprises, Ltd.
http://www.hotsos.com
Upcoming events:
- NCOAUG Training Day, Aug 16 Chicago - Miracle Database Forum, Sep 20-22 Middlefart Denmark - 2003 Hotsos Symposium on OracleR System Performance, Feb 9-12 Dallas
-----Original Message-----
Carmichael
Sent: Tuesday, July 30, 2002 4:49 PM
To: Multiple recipients of list ORACLE-L
Cary,
you said
"* Don't embed the object type in the object's name. I used to see
this
all the time with tablespaces called XYZ_TS, indexes called IND_THING,
and so on."
what's your logic behind that?
Rachel
-- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Rachel Carmichael INET: wisernet100_at_yahoo.com Fat City Network Services -- (858) 538-5051 FAX: (858) 538-5051 San Diego, California -- Public Internet access / Mailing Lists -------------------------------------------------------------------- To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing). -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Cary Millsap INET: cary.millsap_at_hotsos.com Fat City Network Services -- (858) 538-5051 FAX: (858) 538-5051 San Diego, California -- Public Internet access / Mailing Lists -------------------------------------------------------------------- To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing). -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Stephen Andert INET: StephenAndert_at_firsthealth.com Fat City Network Services -- (858) 538-5051 FAX: (858) 538-5051 San Diego, California -- Public Internet access / Mailing Lists -------------------------------------------------------------------- To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).Received on Tue Jul 30 2002 - 18:43:40 CDT