http://www.perlmonks.org?node_id=429004

perlsen has asked for the wisdom of the Perl Monks concerning the following question:

Hi monks,

I have to connect the mysql database using DBI.

I am having the perl version of 5.6. and 5.8.4.
i have seen lot of dbi versions are available in cpan.

so that Which dbi version can i download that can compatible for my perl versions.
and also please tell me which perl can i use for the dbi connection?.

Thanks for your Reply and suggestions.

  • Comment on Which version of DBI download for perl 5.6. and 5.8.4.?.

Replies are listed 'Best First'.
Re: Which version of DBI download for perl 5.6. and 5.8.4.?.
by htoug (Deacon) on Feb 08, 2005 at 11:11 UTC
    Use the latest unless you have a specific reason not to.

    Latest version is 1.47, and AFAIR it has been tested with MySQL.

Re: Which version of DBI download for perl 5.6. and 5.8.4.?.
by leriksen (Curate) on Feb 08, 2005 at 12:42 UTC
    DBI dropped compatibility with Perl's earlier than 5.6.0 at about 1.37 - currently they support 5.6+ with every release, until they advise otherwise.

    I know this because we still have some old Solaris boxes with the default Perl 5.005 installed, and we have to use DBI 1.37 with those, later versions moan vociferously about an 'ancient perl'.

    ...it is better to be approximately right than precisely wrong. - Warren Buffet

Re: Which version of DBI download for perl 5.6. and 5.8.4.?.
by elbow (Scribe) on Feb 08, 2005 at 12:09 UTC
    I'd also recommend using DBD::mysql with DBI. I found it very straightforward for my first database accesses with perl.

    elbow