[prev in list] [next in list] [prev in thread] [next in thread] 

List:       php-general
Subject:    Re: [PHP3] Database Design
From:       "Manuel Lemos" <mlemos () acm ! org>
Date:       1999-11-08 21:19:37
[Download RAW message or body]

Hello Dean,,

On 08-Nov-99 14:15:44, you wrote:

>Recently I have taken a look at the DDL code used in many of the Data Table
>used as part of PHP applications. And the one thing that strikes me is that
>the writer has unnecessarily worked very hard on the scripts. What I mean is
>let the under lying RDBMS do the work. I lot of time and effort could be
>save if Data Tables were properly designed. In the DDL I have looked at
>nobody has 'normalized' the tables, there is no use of referential
>integrity, no check contraints, etc. Good design would save hours of PHP
>coding. What about it guys?
>This message is meant to open up a debate. It not meant the negatively
>critises (flame) anybody, so please don't be offended.

Of course you are right, but the reality is that people don't use databases
because they are good designers but rather because they are required to
make their applications run.

Most people are only concerned with version 1.0 of their software.  They
are not able to antecipate the needs of future versions, so they just
design for what they need now, taking as less time as possible.  Then what
you see, is the usual waste of time of redoing everything from scratch
dumping the previous design (or whatever you may call it).

As for database design, usually I draw a simple UML schema to figure if I
have defined all the data structures and relations that I need.  If the
application is above a certain level of complexity I usually depart from
a formal requirements specification and the evolve to a detailed
specification from which I design the application database schema.

This is boring and a lot of people avoid doing that way also because of
that.  So it is just not a matter knowledge, it's also a matter of
motivation.

Motivation is also the reason for people avoiding to evolve their
applications with new features, because the maintenance effort to change
anything in their database structure is huge when they don't have the tools
to do it.

The good news for PHP developers is that I developed a package that is used
as a tool for achieving a few interesting things. One is the development of
database independent applications.  Another is the ability to install and
maintain databases with almost no work.

The database independence provides means to interface any SQL RDBMS with
the same set of functions.  Besides what usual DBI-DBD like packages offer,
my package provides database abstraction for less normalized things like
prepared queries, access to sequences, transactions, etc..

The real good value comes with the part that lets you define database
schemas in a XML based format and have it installed without any knowledge
of creation databases, tables, indexes, sequences, etc..

What's really cool about this is that it is also able to upgrade the
database to a new schema without disturbing existing data.  Just provide
the package the new version of the database definition XML file and it
applies the schema changes by itself.  You can do almost evrything allowed
like adding, removing or changing tables, fields, indexes and sequences.

I have been promising to release for free for a while.  It is ready but I
wanted to provide proper documentation before releasing it to the PHP
crowd. I have been terribly busy but hopefully I will be able to do it
some time soon, possibly before the end of this month. Stay tuned.



>In this world without borders or fences
>Who needs Windows or Gates?

Nobody, but don't worry, in no more than 2 years of upcoming trials and
recourses, there won't be any Windows or Gates to worry about because all
Windows will be forced to be Open Source and Gates stocks will be worth
nothing. It will be the end of of the era of what used to be micro and soft.


Regards,
Manuel Lemos

Web Programming Components using PHP Classes.
Look at: http://phpclasses.UpperDesign.com/?user=mlemos@acm.org
--
E-mail: mlemos@acm.org
URL: http://www.mlemos.e-na.net/
PGP key: http://www.mlemos.e-na.net/ManuelLemos.pgp
--


-- 
PHP 3 Mailing List <http://www.php.net/>
To unsubscribe, send an empty message to php3-unsubscribe@lists.php.net
To subscribe to the digest, e-mail: php3-digest-subscribe@lists.php.net
To search the mailing list archive, go to: http://www.php.net/mailsearch.php3
To contact the list administrators, e-mail: php-list-admin@lists.php.net

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic