O'Reilly logo

PostgreSQL 9 Administration Cookbook by Hannu Krosing, Simon Riggs

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Choosing good names for database objects

The easiest way to help other people understand a database is to make sure that all the objects have a meaningful name.

What makes a meaningful name?

How to do it...

  • The name follows the existing standards and practices in place. Inventing new standards isn't helpful; enforcing existing ones is.
  • The name clearly describes the role or table contents.
  • For major tables use short, powerful names.
  • For lookup tables, name them after the table to which they are linked, such as account_status.
  • For associative or linked tables, use all of the names of the major tables to which they relate, such as customer_account.
  • Make sure that the name is clearly distinct from other similar names.
  • Use consistent abbreviations.
  • Use underscores. ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required