On Tue, Apr 22, 2008 at 6:09 PM, Daniel Convissor
<[EMAIL PROTECTED]> wrote:
> Hi John:
>  [snip]
>  Don't use sub selects unless really necessary.  They kill performance.

Yeah, that's why I knew what I was doing was wrong.

>  Also also, use a consistent naming convention.  You've got plural
>  descriptions and singular product.

While that was just an example, I am a bit stuck with legacy naming
that is all over the place.  I am not aware of any good method for
fixing a schema naming problem without a huge amount of
changes/testing.  I suppose I could create a bunch of views and fix it
piecemeal, but that will likely cause a ton of headaches.

Is there a defacto standard for schema naming?  For new stuff, I have
gone with table names as plural, and first letter is upper case, and
words separated by underscores.  Field names are lower case, separated
by underscores. Field keys should have the same name across all tables
to allow for USING.   I never know what to name timestamp/date fields.

How would you name the following tables?
Users
Permissions
User_Permissions  - a many to many connector table

Thanks,
John Campbell
_______________________________________________
New York PHP Community Talk Mailing List
http://lists.nyphp.org/mailman/listinfo/talk

NYPHPCon 2006 Presentations Online
http://www.nyphpcon.com

Show Your Participation in New York PHP
http://www.nyphp.org/show_participation.php

Reply via email to