News Feed
Sections




News Archive
Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

IBM developerWorks:
Five common PHP database problems
August 02, 2006 @ 06:08:41

It seems like there's not a site out there anymore that doesn't use a database of some sort. Frankly, they're just a simple way to get the storage you need without the hassle of having to manage the resource yourself. It even comes with its own language to help query the data! Of course, with the good comes the bad, and this new article from IBM's developerWorks site about five common database mistakes.

If only there were one way to use databases correctly... You can create database design, database access, and the PHP business logic code that sits on top of it in any number of ways, and you often end up getting it wrong. This article illustrates five common problems in database design, in the PHP code that accesses databases, and how to fix these problems when you see them.

The problems they discuss are:

  • Using MySQL directly
  • Not using auto-increment functionality
  • Using multiple databases
  • Not using relations
  • The n+1 pattern
Each of the items is discussed and explained with code samples for both the good and the bad side to make comparison easier. Knowing these issues before you develop your system definitely makes it easier, but they're still useful as a tool to fix things as well.

0 comments voice your opinion now!
common five database problems mysql autoincrement relations common five database problems mysql autoincrement relations


blog comments powered by Disqus

Similar Posts

DevShed: Creating a Login Script for a PHP Invoicing System

WebReference.com: Database-enabled Ajax with PHP

Edin Kadribasic's Blog: PHP 4.4.6-win32 with MySQL 5.0.36

Stefan Mischook's Blog: Introduction to MySQL Video Tutorial

WebReference.com: Accessing Your MySQL Database from the Web with PHP


Community Events





Don't see your event here?
Let us know!


podcast series list symfony2 configure framework language testing unittest refactor introduction community laravel threedevsandamaybe interview developer opinion code install release

All content copyright, 2014 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework