• Eshika (3/6/2014)


    I am trying to establish the standards for naming convention in my new project. Can you please provide me the best standards which worked for you.

    Thanks

    Esha

    This is more personal preference than anything to be honest. I personally detest prefixes so I don't use them at all. Things like usp_ to indicate that the object is a user stored procedure just create noise and make it hard to find things.

    Generally speaking I name tables as a collection of whatever object it holds. That means plural (Accounts, Users, etc).

    Procedures usually have some sort of verb in them to indicate some level of functionality. I like to use the object first followed by the verb so they will sort nicely. Accounts_Insert, Accounts_Update for example.

    There are many ideas and opinions on this as there are people on the planet. There is not right or wrong way. Well mostly that is true. The right way is to be consistent, the wrong way is to be inconsistent. 😉

    _______________________________________________________________

    Need help? Help us help you.

    Read the article at http://www.sqlservercentral.com/articles/Best+Practices/61537/ for best practices on asking questions.

    Need to split a string? Try Jeff Modens splitter http://www.sqlservercentral.com/articles/Tally+Table/72993/.

    Cross Tabs and Pivots, Part 1 – Converting Rows to Columns - http://www.sqlservercentral.com/articles/T-SQL/63681/
    Cross Tabs and Pivots, Part 2 - Dynamic Cross Tabs - http://www.sqlservercentral.com/articles/Crosstab/65048/
    Understanding and Using APPLY (Part 1) - http://www.sqlservercentral.com/articles/APPLY/69953/
    Understanding and Using APPLY (Part 2) - http://www.sqlservercentral.com/articles/APPLY/69954/