I Usually do some like

Eg USERS TABLE

TABLE
USR_USERS or for Company Users can be CMP_USERS or Application Abbrv+Usage

FIELDS
USR_ID Or CMP_USERID
USR_LOGON_ID
USR_FNAME
USR_MNAME
USR_LNAME
USR_EMAIL ...
and name stored procedures after app name
eg CFApplication name="xyz_secure"

xyx_ProcName or xyz_chkUserLogin


Joe

----- Original Message -----
From: "Smith, Matthew P -CONT(DYN)" <[EMAIL PROTECTED]>
To: "CF-Talk" <[EMAIL PROTECTED]>
Sent: Wednesday, June 12, 2002 11:51 AM
Subject: RE: DB Table Naming Conventions


> Lol, same answer, same time.
>
> Matt
>
>
> -----Original Message-----
> From: Joshua Tipton [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, June 12, 2002 10:44 AM
> To: CF-Talk
> Subject: RE: DB Table Naming Conventions
>
> proc_
>
> -----Original Message-----
> From: Joshua Miller [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, June 12, 2002 11:32 AM
> To: CF-Talk
> Subject: RE: DB Table Naming Conventions
>
>
> Really? Wow ... I didn't know that. How do you prefix or designate
> Stored Proceedures?
>
> Joshua Miller
> Web Development :: Programming
> Eagle Web Development LLC
> www.eaglewd.com
> [EMAIL PROTECTED]
> (304) 622-5676 (Clarksburg Office)
> (304) 456-4942 (Home Office)
>
>
> -----Original Message-----
> From: Joshua Tipton [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, June 12, 2002 11:23 AM
> To: CF-Talk
> Subject: RE: DB Table Naming Conventions
>
>
> MS says that only system stored procedures should start with sp becasue
> when sql recieves a stored proc with sp_ it looks in the master system
> stored procedures first then looks in the current database.  I doubt the
> speed difference is that much but just a tidbit of my two cents.
>
> Josh
>
> <!--- Cut out of Books Online --->
>
> Many of your administrative activities in MicrosoftR SQL ServerT are
> performed through a special kind of procedure known as a system stored
> procedure. System stored procedures are created and stored in the master
> database and have the sp_ prefix. System stored procedures can be
> executed from any database without having to qualify the stored
> procedure name fully using the database name master.
>
> It is strongly recommended that you do not create any stored procedures
> using sp_ as a prefix. SQL Server always looks for stored procedures
> beginning with sp_ in this order:
>
> Look for the stored procedure in the master database first. Look for the
> stored procedure based on any qualifiers provided (database name or
> owner). Look for the stored procedure using dbo as the owner, if one is
> not specified. Therefore, although the user-created stored procedure
> prefixed with sp_ may exist in the current database, the master database
> is always checked first, even if the stored procedure is qualified with
> the database name.
>
>
> -----Original Message-----
> From: Joshua Miller [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, June 12, 2002 11:10 AM
> To: CF-Talk
> Subject: RE: DB Table Naming Conventions
>
>
> We usually do something like so:
>
> Stored Proc: sp_whatever
> Views: vw_whatever
> Tablename: tblUsers, tblPermissions, etc.
> Fields: Always prefixed with table-related text as such:
> userID (PK/ID)
> ufirstname
> ulastname
> uaddress1
> uaddress2
> ucity
> ustate
> uzip
> etc.
>
> That just makes it easier for me to see what field is related to what
> table - especially when you have similar data in multiple fields (which
> we try to avoid by abstracting the database as much as possible - but
> sometimes is necessary).
>
> There may be a better way or a more suitable way for your programming
> style.
>
> Joshua Miller
> Web Development :: Programming
> Eagle Web Development LLC
> www.eaglewd.com
> [EMAIL PROTECTED]
> (304) 622-5676 (Clarksburg Office)
> (304) 456-4942 (Home Office)
>
>
> -----Original Message-----
> From: Zac Spitzer [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, June 12, 2002 10:20 AM
> To: CF-Talk
> Subject: Re: DB Table Naming Conventions
>
>
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> [EMAIL PROTECTED] wrote:
> | I'm just curious, What naming conventions for DB tables do you use?
>
>
> this is a biggy :-) a lot of php developers that work with mysql, a non
> relational db use pk names of ID....
>
> I always name the pk of table  (table_name)_id...  I also tend to prefix
> ~ column names with an abbreviation of the table name, it makes life
> easier as there is more information there and when you start joining
> tables, there is less conflict if u use common naming conventions
>
> z
>
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.0.6-2 (MingW32)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
>
> iEYEARECAAYFAj0HWKMACgkQm98oI6K7h0gxUQCgjUvOt0+YVHgz/Qyh8RlAawAp
> CrwAoOwShhA1t7xZpiKsaYQ3Cdz8Supo
> =YXc3
> -----END PGP SIGNATURE-----
>
>
>
>
>
>
> 
______________________________________________________________________
Get the mailserver that powers this list at http://www.coolfusion.com
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to