Take the 2-minute tour ×
Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. It's 100% free, no registration required.

I learned at the University some steps to model a database:

  1. Model the problem using the Extended Entity-Relationship Model.
  2. Extract the functional dependencies
  3. Apply some algorithms to normalize the database (3NF or Boyce-Codd)
  4. Create the database

I'm studying Computer Science and since I received that course I'm wondering if I always need to do those steps when creating a complex database for an specified problem.

For example, do PHP / .NET / .. programmers always do that? or there are some tools to simplify that process, maybe using another way of represent the problem instead of the EERM?

share|improve this question

4 Answers 4

up vote 1 down vote accepted

Modeling a database is like putting the carriage before the horse. I'd say if anything stop at Entity-Relationship modeling. This is generic enough that you can move from there to Object Modeling which is where the meat of your application lies. The database is there for persistence. The most important thing is getting your class model correct, then you can map the database to support it.

share|improve this answer

You can use UML instead of ER diagram, if you are familiar with UML. I would suggest Database Modeling and Design: Logical Design book, it has an example how to convert your domain problem into SQL world.

share|improve this answer
    
would that simplify those steps? I mean, will I have a normalized database using UML?... –  Oscar Mederos Feb 8 '11 at 5:56
    
It's depends on your database plan, tools won't normalized for us. –  Abimaran Kugathasan Feb 8 '11 at 6:09

I started using Object Role Modelling recently with the NORMA tool

It compresses points 1 to 3 above, and can generate the script/XSD for point 4.

share|improve this answer

It depends on your skill set. If you are a database administrator then you might follow the steps that you described because in this case you want to reduce the cost of queries and maintain/improve data integrity.

However, if you're a developer you probably want your application to compile/build/run as a priority and abstract your storage mechanism using an Object Relational Model (ORM) in which case you will think of your persistence more in terms of object relations than entity relations. So you would

  • Choose your application stack
  • Code your object functions and properties
  • Perform some action on objects including updating properties
  • Save objects to storage
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.