Stories
Slash Boxes
Comments
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
 Full
 Abbreviated
 Hidden
More | Login | Reply
Loading... please wait.
  • by dennisdjensen (8668) on 2008.06.03 17:36 (#63147)
    I and my colleagues have encountered all of the issues and some more with O/R-mapping and tools as you've described above.

    We still haven't found the sweet spot.

    Sometimes O/R-mapping is a big winner and a really productivity booster as well as a good abstraction. At other times it just blows up in your face, and a few well chosen SQL-statements with suitable interpolation does it all. Sometimes integrating the O/R-tool with the domain objects works better, at other times it works better when we treat it as a separate layer. The business logic can be anywhere! Sometimes it is most helpful, even necessary, to put all of the business logic (as much as possible) into the database. This requires good knowledge of not only SQL, but relational theory (C.J. Date and friends). Again, many possibilities. At other times it is hardly worth it to put too many constraints upon the data, where application logic and business logic melts together, and any constraint comes from the application itself (minimum databases, in-memory, filesystems, pure blocks of words).

    I think Martin Fowler wrote a little about this at some time, but I cannot find it again. He mentioned the different styles a project would go through as it matured or just grew. From simple embedded SQL to full blown expression builders to meta and behind-the-scenes automagic stuff (think gemstone here).

    Everything has its price. Like so many things, it is a trade-off.

    In my personal, and some of my colleague's, experience (depending very much upon how good at SQL and data theory they are!), O/R-mapping are seldom good at anything but prototyping or a kicker to get started quickly on a new project.