Solved

MySQL standard

Posted on 2013-10-25
4
296 Views
Last Modified: 2013-11-01
I am brand new to mySQL and need to develop a standard for all mySQL databases for my company.

i do not even know where to start and what to include into the document. Any ideas?
0
Comment
Question by:YZlat
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 3

Accepted Solution

by:
Peter Haussl earned 125 total points
ID: 39600545
Hi,

Start with naming conventions and used data types. Which is in order to keep the overview very important especially when it is about a big amount of tables.

e.g. start names of tables with an tusers and so called views with an vuser.

Additionally Standard for database design should also include how fieldnames are called.
e.g. if Primary keys have to have a Special Name in order to have them the same way designed.

All the rest is quite depened on your businesscase and size and amount of tables.

br
Peter

[edit] within the following link you will find also example in order to get an idea. This example is related to Oracle database, i found on Google.

http://www.google.at/url?sa=t&rct=j&q=&esrc=s&source=web&cd=6&cad=rja&ved=0CHAQFjAF&url=http%3A%2F%2Fwww.bced.gov.bc.ca%2Fimb%2Fdownloads%2Fodeveguide2.doc&ei=q4hqUsDeDKjb0QXi7oCQBQ&usg=AFQjCNF_gcFdussc_EIKJn9ZIoxP3Ihwfg&bvm=bv.55123115,d.Yms

They are also including Terms of projectmembers (DBA,...) and their responsibilities.
How stored procedures needs to be coded,....

Maybe it is useful for your Job.
0
 
LVL 32

Assisted Solution

by:Daniel Wilson
Daniel Wilson earned 125 total points
ID: 39601034
Yeah, naming conventions, data types, and key conventions are the place to start.  I'm not a fan of prefixes for tables, but their use or non-use should be standardized for the organization.

You should standardize whether table names are singular or plural.  Whether the tables are Customer or Customers makes no real difference, but remembering that the Customer table links to the Orders table which links to the OrderDetail table which links to the Products table ... because singular vs plural was whimsical becomes a real drag.

Capitalization enters the picture too.  Will your names be CamelCase, underscored_lower, etc?  It's a matter more of preference than anything, but should be standardized so that remembering the names is easy.

Beyond the Primary key, will you require foreign keys?  What rule will be used on deletion? There's no one-size-fits-all right answer (though this is closer to right/wrong than the naming convention is), but it should be standardized.

Also, what storage engine will you use?  Better to determine early what you will use (and what exceptions might be) than to go with defaults or let each developer make his own choice without consideration of the relative advantages of each.
0
 
LVL 110

Expert Comment

by:Ray Paseur
ID: 39603785
The kind of thing you're describing is usually done by a full time four year college engineering major.

I think I would start by making a Google search for "learning mysql" and would follow the many good links that can point you to learning resources.  You will quickly see that this is not a good area to be guessing, especially since you're going to be setting the foundation for your company's applications.  Once you have done that, you might want to go to a nearby college or university and hire someone in the computer science department who is an expert in data base design and administration.  You can make a modest investment now and enjoy a strong foundation for growth or you can spend your career struggling, patching and repairing a botched design.  

I've seen this happen too many times.  As but one example of what can go wrong, consider the rollout of the US healthcare.gov web site.  They spent over half a billion dollars but because they started with flawed underpinnings the site still does not work, and is a huge embarrassment for the administration!

As the great oil-well firefighter Red Adair famously said, "If you think it's expensive to hire a professional, just wait till you hire an amateur!"
0
 
LVL 35

Author Closing Comment

by:YZlat
ID: 39617785
thanks!
0

Featured Post

How Do You Stack Up Against Your Peers?

With today’s modern enterprise so dependent on digital infrastructures, the impact of major incidents has increased dramatically. Grab the report now to gain insight into how your organization ranks against your peers and learn best-in-class strategies to resolve incidents.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
category table 2 43
converting integer data type to time data type in sql 4 60
Duplicated data in GROUP_CONCAT 2 52
mysql vs miscrosoft sql server 6 62
Foreword This article was written many years ago, in the days when PHP supported the MySQL extension (http://php.net/manual/en/function.mysql-connect.php).  Today (http://php.net/manual/en/migration70.removed-exts-sapis.php) you would not use MySQL…
Load balancing is the method of dividing the total amount of work performed by one computer between two or more computers. Its aim is to get more work done in the same amount of time, ensuring that all the users get served faster.
This video shows how to use Hyena, from SystemTools Software, to update 100 user accounts from an external text file. View in 1080p for best video quality.

751 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question