Slash Boxes
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.
More | Login | Reply
Loading... please wait.
  • by vek (2312) on 2003.06.20 8:12 (#21279) Journal
    Don't forget the DBI abstraction layer :-)
    • Yeah, I've noticed this one too. I can understand having a Class to create the DBI handle (no need to remember pwords, usernames, etc), but it seems that everywhere I've worked people want to replace DBI's methods with their own (which simply wrap the basic ones). DBI has everything I've ever wanted to do with a database, and then some. Using DBI makes it easier for new people to come in and know exactly what's going on, without having to understand someone else's idea of what database access *should* be.
      • After you've written your 39823th slight variation on the basic SELECT, INSERT and UPDATE statements, it gets a little tiresome.
    • There can be good reasons for it.

      The wrapper that I continually reuse, implements a keyword lookup into a Class::Phrasebook XML file. This has meant I have been able to move from MySQL to MS SQL Server 7, by only changing the XML file. Plus my wrapper creates the DBI object for you, but only if you require it. I have seen several implementations of CGI scripts that create a connection, even when the request never uses it.

      Although Class::DBI may be growing in popularity it doesn't suit all purposes, and